Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#825: Allow passing explicit connection to '_PropertyMixin.{reload,patch}'. #852

Merged
merged 2 commits into from
May 4, 2015
Merged

#825: Allow passing explicit connection to '_PropertyMixin.{reload,patch}'. #852

merged 2 commits into from
May 4, 2015

Conversation

tseaver
Copy link
Contributor

@tseaver tseaver commented May 1, 2015

See #825.

@tseaver tseaver added the api: storage Issues related to the Cloud Storage API. label May 1, 2015
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label May 1, 2015
@coveralls
Copy link

Coverage Status

Coverage remained the same at 100.0% when pulling 843a50e on tseaver:825-storage_property_mixin-allow_explicit_connection into fb59514 on GoogleCloudPlatform:master.

@tseaver
Copy link
Contributor Author

tseaver commented May 1, 2015

@dhermes PTAL

the object in its constructor.
"""
if connection is None:
connection = self.connection

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

@tseaver
Copy link
Contributor Author

tseaver commented May 4, 2015

FWIW forcing use of _require_connection inside _PropertyMixin.{reload,patch} makes this a bigger PR: we have to chase all the tests in derived classes which don't set up the implicit default.

@tseaver
Copy link
Contributor Author

tseaver commented May 4, 2015

I was wrong there: the test failures were due to storage.api.get_bucket, which wasn't passing through the explicit connection to bucket.reload.

@tseaver
Copy link
Contributor Author

tseaver commented May 4, 2015

@dhermes Rebased w/ protobuf version pin fix, and changed to use _require_connection. PTAL

@@ -33,11 +33,6 @@ class _PropertyMixin(object):
"""

@property
def connection(self):

This comment was marked as spam.

@dhermes
Copy link
Contributor

dhermes commented May 4, 2015

LGTM

tseaver added a commit that referenced this pull request May 4, 2015
…_explicit_connection

#825: Allow passing explicit connection to '_PropertyMixin.{reload,patch}'.
@tseaver tseaver merged commit 2cdaeb2 into googleapis:master May 4, 2015
@tseaver tseaver deleted the 825-storage_property_mixin-allow_explicit_connection branch May 4, 2015 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: storage Issues related to the Cloud Storage API. cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants