GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Decouple connection from Blob by dhermes · Pull Request #823 · googleapis/google-cloud-python

Conversation

@dhermes

@dhermes dhermes commented Apr 14, 2015

Copy link
Copy Markdown
Contributor

NOTE: Has #822 as diffbase.

Towards #728

@tseaver I made a separate commit for each method with used Blob.connection but can combine them if you like.

I wanted to get rid of the Blob.connection property, but _PropertyMixin.reload() and _PropertyMixin.patch() use it as well as ObjectACL.reload() and ObjectACL.save().

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@dhermes dhermes added the api: storage Issues related to the Cloud Storage API. label Apr 14, 2015
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Apr 14, 2015
@dhermes dhermes changed the title Decouple connection in blob Decouple connection from Blob Apr 14, 2015
@coveralls

coveralls commented Apr 14, 2015

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 5cf9023 on dhermes:decouple-connection-in-blob into 6283ab9 on GoogleCloudPlatform:master.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tseaver

tseaver commented Apr 15, 2015

Copy link
Copy Markdown
Contributor

9932f0d LGTM
e429f9a LGTM
8ebb280 see comments inline (setting connection=None in ctors to verify that override is used)
824ff20 same issue
5cf9023 same issue

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes
dhermes force-pushed the decouple-connection-in-blob branch from 5cf9023 to a54b630 Compare April 15, 2015 21:50
@dhermes

dhermes commented Apr 15, 2015

Copy link
Copy Markdown
Contributor Author

@tseaver I imagine this being a transient issue since at some point connection will not be bound to any of the types or to the stubs.

I'm not sure what would need to be checked either.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

@dhermes in the tests, we should pass None to the bucket ctor in order to ensure that the passed-in connection is being used (the tests as we have them would pass if the methods took the connection argument, but then fell back to using self.connection).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

The heisenbug that @jgeewax fixed in #834 raised it's head here too. Only the 2nd time I had seen (build failure was first). Will rebase.


@tseaver All the Blob methods I changed use the passed in connection only and don't fall back to self.connection.

They are moving towards no connection anywhere, so falling back is a no-no.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes
dhermes force-pushed the decouple-connection-in-blob branch from a54b630 to ca34a4a Compare April 16, 2015 16:30
@coveralls

coveralls commented Apr 16, 2015

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling ca34a4a on dhermes:decouple-connection-in-blob into 40d84e9 on GoogleCloudPlatform:master.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

That's why having the bucket initialized with an invalid connection is the Right Thing (TM): it ensures that fallback cannot cause the test to succeed.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

Gotcher. Current plan is to cherry-pick each of the 5 commits and then replace Bucket(connection) with Bucket(None) or similar. (About to spend an hour without internet on BART.)

LMK if this is a bad idea.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes
Moving _require_connection from storage.api to helpers.
e5a72fd
This is to blob and bucket can use it without import cycles.
@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

SGTM

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

dhermes added 4 commits April 16, 2015 10:17
@dhermes
Removing using of Blob.connection in generate_signed_url.
e3ccb8d
Allowing the default connection to be used or direct use of
a credentials object.
@dhermes
Removing using of Blob.connection in Blob.exists().
0421117
Allowing the default connection to be used.
@dhermes
Removing using of Blob.connection in all Blob.download* methods.
970beaa
Allowing the default connection to be used as fallback or takes
an explicit connection argument.
@dhermes
Removing using of Blob.connection in all Blob.upload* methods.
60d43ac
Allowing the default connection to be used as fallback or takes
an explicit connection argument.
@dhermes
dhermes force-pushed the decouple-connection-in-blob branch from ca34a4a to 60d43ac Compare April 16, 2015 18:24
@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

@tseaver PTAL

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@coveralls

coveralls commented Apr 16, 2015

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 60d43ac on dhermes:decouple-connection-in-blob into 40d84e9 on GoogleCloudPlatform:master.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

LGTM

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

dhermes added a commit that referenced this pull request Apr 16, 2015
@dhermes
Merge pull request #823 from dhermes/decouple-connection-in-blob
06e26ad
Decouple connection from Blob
@dhermes
dhermes merged commit 06e26ad into googleapis:master Apr 16, 2015
@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

@tseaver Can we divvy up work and try to close out #728 together?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes
dhermes deleted the decouple-connection-in-blob branch April 16, 2015 19:31
@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

How do you see the split?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

Can you handle the methods in acl.py and I'll try to cover the rest (Bucket and _PropertyMixin)?

Then we "converge" and remove the connection property from Blob (it gets used in acl.py).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tseaver

tseaver commented Apr 16, 2015

Copy link
Copy Markdown
Contributor

OK. I just inventoried those methods in #825.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes

dhermes commented Apr 16, 2015

Copy link
Copy Markdown
Contributor Author

Awesome! Thanks

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dhermes dhermes mentioned this pull request Jun 4, 2015
Upgrading version to 0.6.0. #907
Merged
parthea pushed a commit that referenced this pull request Aug 21, 2025
@renovate-bot @gcf-owl-bot
chore(deps): update all dependencies (#823)
dc959ef
* chore(deps): update all dependencies

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Sep 16, 2025
@renovate-bot @gcf-owl-bot @parthea
chore(deps): update all dependencies (#823)
5e160ec
* chore(deps): update all dependencies

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Sep 18, 2025
@gcf-owl-bot
build: use multiScm for Kokoro release builds (#823)
706d9bd
Source-Link: googleapis/synthtool@0da1658
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:5cddfe2fb5019bbf78335bc55f15bc13e18354a56b3ff46e1834f8e540807f05

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Nov 24, 2025
@release-please
chore: release 0.43.2 (#823)
a206187
🤖 I have created a release \*beep\* \*boop\*
---
### [0.43.2](https://www.github.com/googleapis/gapic-generator-python/compare/v0.43.1...v0.43.2) (2021-03-24)


### Bug Fixes

* add certain raw imports to RESERVED_NAMES ([#824](https://www.github.com/googleapis/gapic-generator-python/issues/824)) ([04bd8aa](https://www.github.com/googleapis/gapic-generator-python/commit/04bd8aaf0fc2c2c0615105cab39dc33266b66775))
* Update module alias to resolve naming conflict ([#820](https://www.github.com/googleapis/gapic-generator-python/issues/820)) ([f5e9f36](https://www.github.com/googleapis/gapic-generator-python/commit/f5e9f367ec6a72b4272f559a93f6fbb3d7e54b8b)), closes [#819](https://www.github.com/googleapis/gapic-generator-python/issues/819)
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
parthea pushed a commit that referenced this pull request Nov 24, 2025
@gkevinzheng
fix: Ignore Python37DeprecationWarnings from google.auth (#823)
e12c723
parthea pushed a commit that referenced this pull request Nov 25, 2025
@gkevinzheng
fix: Ignore Python37DeprecationWarnings from google.auth (#823)
11de952
parthea pushed a commit that referenced this pull request Nov 26, 2025
@release-please
chore: release 2.0.0b1 (#823)
2c18d91
parthea pushed a commit that referenced this pull request Mar 6, 2026
@gcf-owl-bot
chore: store artifacts in placer (#823)
3e5103a
Source-Link: googleapis/synthtool@cb96037
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:2d816f26f728ac8b24248741e7d4c461c09764ef9f7be3684d557c9632e46dbd

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
parthea added a commit that referenced this pull request Mar 9, 2026
@renovate-bot @parthea
chore(deps): update dependency google-cloud-pubsub to v2.13.1 (#823)
e762032
Co-authored-by: Anthonios Partheniou <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

api: storage Issues related to the Cloud Storage API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@dhermes @coveralls @tseaver @googlebot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.