Skip to content

Separating _patch_properties and PATCH on Bucket. - #683

Merged
dhermes merged 1 commit into
googleapis:masterfrom
dhermes:patch-bucket-imperative
Mar 5, 2015
Merged

Separating _patch_properties and PATCH on Bucket.#683
dhermes merged 1 commit into
googleapis:masterfrom
dhermes:patch-bucket-imperative

Conversation

@dhermes

Copy link
Copy Markdown
Contributor

@tseaver there is plenty to discuss here and I will enumerate.

In the immediately relevant category is my uses of self.patch() in several of the methods. I was unclear if we think they should be setters or actual API requests.

Relates to #632.

@googlebotgooglebot added the cla: yes This human has signed the Contributor License Agreement. label Feb 26, 2015
@dhermes

Copy link
Copy Markdown
ContributorAuthor

Some other things to worry about

  1. In the future where connection is not bound to Bucket
defpatch(self, connection=None):
self._properties=connection.api_request(...

This would be a 204 on a Batch and do very much the wrong thing
2. Most getters use _PropertyMixin.properties, which is always an API request (See #688)
3. Blob.metadata (setter) is the only use of _patch_properties there in Blob. It seems _scalar_property was the biggest user. (See #690, it changes _patch_properties everywhere.)
4. This may break _PropertyBatch as it replaces _patch_properties on enter and puts it back on exit. (See #690, it changes __exit__.)

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling cdd6694 on dhermes:patch-bucket-imperative into 51e286f on GoogleCloudPlatform:master.

@dhermes

Copy link
Copy Markdown
ContributorAuthor

@tseaver PTAL

@tseaver

Copy link
Copy Markdown
Contributor

LGTM.

dhermes added a commit that referenced this pull request Mar 5, 2015
Separating _patch_properties and PATCH on Bucket.
@dhermes
dhermes merged commit ef1a3da into googleapis:masterMar 5, 2015
@dhermes
dhermes deleted the patch-bucket-imperative branch March 5, 2015 18:37
parthea added a commit that referenced this pull request Nov 22, 2025
* feat: remove proto ReadEfficiencyStats
feat: remove field RequestStats.read_efficiency_stats
feat: rename proto AllReadStats to FullReadStatsView
feat: rename field RequestStats.all_read_stats to full_read_stats_view
feat: rename proto ReadIteratorStats to ReadIterationStats
feat: remove enum value ReadRowsRequest.RequestStatsView.REQUEST_STATS_EFFICIENCY
feat: remove field ReadIterationStats.deletes_seen
PiperOrigin-RevId: 479370243
Source-Link: googleapis/googleapis@959d789
Source-Link: googleapis/googleapis-gen@38b4252
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMzhiNDI1MjY0YzAzZjNjZGNhMjc5NTAzYzgwMWM4NjYwNGM4YTY3YSJ9
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
* chore: update to gapic-generator-python 1.5.0
feat: add support for `google.cloud.<api>.__version__`
PiperOrigin-RevId: 484665853
Source-Link: googleapis/googleapis@8eb249a
Source-Link: googleapis/googleapis-gen@c8aa327
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYzhhYTMyN2I1ZjQ3ODg2NWZjM2ZkOTFlM2MyNzY4ZTU0ZTI2YWQ0NCJ9
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
* chore: Update to gapic-generator-python 1.6.0
feat(python): Add typing to proto.Message based class attributes
feat(python): Snippetgen handling of repeated enum field
PiperOrigin-RevId: 487326846
Source-Link: googleapis/googleapis@da380c7
Source-Link: googleapis/googleapis-gen@61ef576
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNjFlZjU3NjJlZTY3MzFhMGNiYmZlYTIyZmQwZWVjZWU1MWFiMWM4ZSJ9
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
* feat: new APIs added to reflect updates to the filestore service
- Add ENTERPRISE Tier
- Add snapshot APIs: RevertInstance, ListSnapshots, CreateSnapshot, DeleteSnapshot, UpdateSnapshot
- Add multi-share APIs: ListShares, GetShare, CreateShare, DeleteShare, UpdateShare
- Add ConnectMode to NetworkConfig (for Private Service Access support)
- New status codes (SUSPENDED/SUSPENDING, REVERTING/RESUMING)
- Add SuspensionReason (for KMS related suspension)
- Add new fields to Instance information: max_capacity_gb, capacity_step_size_gb, max_share_count, capacity_gb, multi_share_enabled
PiperOrigin-RevId: 487492758
Source-Link: googleapis/googleapis@5be5981
Source-Link: googleapis/googleapis-gen@ab0e217
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYWIwZTIxN2Y1NjBjYzJjMWFmYzExNDQxYzJlYWI2YjY5NTBlZmQyYiJ9
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
* Add gapic_version to google.cloud.bigtable
Manually adjust the import of gapic_version
* chore: Update gapic-generator-python to v1.6.1
PiperOrigin-RevId: 488036204
Source-Link: googleapis/googleapis@08f275f
Source-Link: googleapis/googleapis-gen@555c094
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNTU1YzA5NDVlNjA2NDllMzg3MzlhZTY0YmM0NTcxOWNkZjcyMTc4ZiJ9
* Fix the version
* 🦉 Updates from OwlBot post-processor
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md
* Remove unused import
* Fix the import
* Add release please config and manifest
Add gapic version under bigtable_admin_v2
* Fix path to bigtable in setup.py
* add google.cloud.bigtable_admin
* hardcode bigtable version in owlbot.py
* Remove unused gapic_version.py from bigtable_admin_v2
Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: Mariatta Wijaya <mariattaw@google.com>
Co-authored-by: Mariatta Wijaya <Mariatta@users.noreply.github.com>
Co-authored-by: Anthonios Partheniou <partheniou@google.com>
parthea added a commit that referenced this pull request Nov 24, 2025
* build: use mypy<1.11.0 until #682 is fixed
* add comment
parthea pushed a commit that referenced this pull request Nov 24, 2025
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Nov 24, 2025
parthea pushed a commit that referenced this pull request Nov 25, 2025
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
parthea pushed a commit that referenced this pull request Nov 26, 2025
Move the version from `setup.py` to `google/auth/version.py`. Same as googleapis/python-api-core#80. (see googleapis/python-api-core#27 for motivation). This is option 3 in https://packaging.python.org/guides/single-sourcing-package-version/.
This unblocks a version check I'd like to add in googleapis/python-api-core#134.
Usage:
```py
>>> import google.auth
>>> google.auth.__version__
'1.25.0'
```
parthea pushed a commit that referenced this pull request Mar 6, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yesThis human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@dhermes@coveralls@tseaver@googlebot