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

Remove implicit environ from storage #988

Merged
merged 2 commits into from
Jul 20, 2015

Conversation

dhermes
Copy link
Contributor

@dhermes dhermes commented Jul 14, 2015

Has #987 as diffbase.

@tseaver The 2nd commit in this PR is all over the place. I can try to re-work if it seems too daunting.

It started out as just deleting _implicit_environ and then dealing with all the dependencies. This included

  • ditching gcloud.get_default_project()
  • axing a lot of the implicit test utils
  • swapping the _client_or_connection for _require_client (and moving Bucket._require_client to _PropertyMixin)
  • updating uses of connection (from _client_or_connection) to be client.connection
  • adding client properties to ACL and _PropertyMixin methods
  • removing the storage._require_connection method
  • removing the concept of default bucket and making bucket required in Blob constructor
  • updating Bucket.create so that both the project and connection come from the client
  • removing lots of "implicit" tests that had explicit equivalents

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Jul 14, 2015
tseaver referenced this pull request in dhermes/google-cloud-python Jul 14, 2015
dhermes referenced this pull request in dhermes/google-cloud-python Jul 14, 2015
@tseaver
Copy link
Contributor

tseaver commented Jul 20, 2015

@dhermes Do you plan to rebase here after #987 lands?

@dhermes dhermes force-pushed the remove-storage-implicit-environ branch from e627eaa to cc7af4e Compare July 20, 2015 20:15
@dhermes
Copy link
Contributor Author

dhermes commented Jul 20, 2015

@tseaver Rebased on top of #987

mock_defaults = _DefaultsContainer(*args, **kwargs)
return _Monkey(_helpers, _DEFAULTS=mock_defaults)


def _setup_defaults(test_case, *args, **kwargs):
test_case._replaced_defaults = _helpers._DEFAULTS
_helpers._DEFAULTS = _DefaultsContainer(*args, **kwargs)

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

@tseaver
Copy link
Contributor

tseaver commented Jul 20, 2015

LGTM

dhermes added a commit that referenced this pull request Jul 20, 2015
@dhermes dhermes merged commit 64ceff4 into googleapis:master Jul 20, 2015
@dhermes dhermes deleted the remove-storage-implicit-environ branch July 20, 2015 21:10
@dhermes dhermes mentioned this pull request Jul 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants