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 — 'test_new_bucket_w_ubla' flakes w/ 412 PreconditionFailed · Issue #577 · googleapis/python-storage

This repository was archived by the owner on Mar 31, 2026. It is now read-only.
This repository was archived by the owner on Mar 31, 2026. It is now read-only.

'test_new_bucket_w_ubla' flakes w/ 412 PreconditionFailed #577

Copy link
Copy link
Closed
Closed
'test_new_bucket_w_ubla' flakes w/ 412 PreconditionFailed#577
Copy link
Labels
api: storageIssues related to the googleapis/python-storage API.type: processA process-related concern. May include testing, release, or the like.

Description

@tseaver
tseaver
opened on Sep 2, 2021
Issue body actions

From this failed run:

____________________________ test_new_bucket_w_ubla ____________________________

storage_client = <google.cloud.storage.client.Client object at 0x7fea45c62510>
buckets_to_delete = [<Bucket: new-w-ubla-1630575370947>], blobs_to_delete = []

    def test_new_bucket_w_ubla(
        storage_client, buckets_to_delete, blobs_to_delete,
    ):
        bucket_name = _helpers.unique_name("new-w-ubla")
        bucket = storage_client.bucket(bucket_name)
        bucket.iam_configuration.uniform_bucket_level_access_enabled = True
        _helpers.retry_429_503(bucket.create)()
        buckets_to_delete.append(bucket)

        bucket_acl = bucket.acl
        with pytest.raises(exceptions.BadRequest):
            bucket_acl.reload()

        bucket_acl.loaded = True  # Fake that we somehow loaded the ACL
        bucket_acl.all().grant_read()
        with pytest.raises(exceptions.BadRequest):
>           bucket_acl.save()

tests/system/test_bucket.py:711:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
google/cloud/storage/acl.py:546: in save
    self._save(acl, None, client, timeout=timeout)
google/cloud/storage/acl.py:510: in _save
    retry=None,
google/cloud/storage/client.py:454: in _patch_resource
    _target_object=_target_object,
google/cloud/storage/_http.py:78: in api_request
    return call()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = <google.cloud.storage._http.Connection object at 0x7fea478ae390>
method = 'PATCH', path = '/b/new-w-ubla-1630575370947'
query_params = {'projection': 'full'}
data = '{"acl": [{"role": "READER", "entity": "allUsers"}]}'
content_type = 'application/json', headers = None, api_base_url = None
api_version = None, expect_json = True, _target_object = None, timeout = 60

    def api_request(
        self,
        method,
        path,
        query_params=None,
        data=None,
        content_type=None,
        headers=None,
        api_base_url=None,
        api_version=None,
        expect_json=True,
        _target_object=None,
        timeout=_DEFAULT_TIMEOUT,
    ):
        """Make a request over the HTTP transport to the API.
       ...
        """
        url = self.build_api_url(
            path=path,
            query_params=query_params,
            api_base_url=api_base_url,
            api_version=api_version,
        )

        # Making the executive decision that any dictionary
        # data will be sent properly as JSON.
        if data and isinstance(data, dict):
            data = json.dumps(data)
            content_type = "application/json"

        response = self._make_request(
            method=method,
            url=url,
            data=data,
            content_type=content_type,
            headers=headers,
            target_object=_target_object,
            timeout=timeout,
        )

        if not 200 <= response.status_code < 300:
>           raise exceptions.from_http_response(response)
E           PreconditionFailed: 412 PATCH https://storage.googleapis.com/storage/v1/b/new-w-ubla-1630575370947?projection=full&prettyPrint=false: One or more users named in the policy do not belong to a permitted customer.

Activity

  1. tseaver
    added
    type: processA process-related concern. May include testing, release, or the like.
    on Sep 2, 2021
  2. product-auto-label
    added
    api: storageIssues related to the googleapis/python-storage API.
    on Sep 2, 2021
  3. tseaver commented on Sep 2, 2021

    @tseaver
    tseaver
    on Sep 2, 2021
    ContributorAuthor
    More actions

    @frankyn, @andrewsg, @cojenco I can't see any reason for the error: has something on the back-end changed?

  4. tseaver
    added a commit that references this issue on Sep 2, 2021

    tests: use an '@google.com' principal for test

    This issue will close once commit 7cbcc5b is merged into the 'main' branch.
    7cbcc5b
  5. tseaver
    closed this as completedin d0f45e9on Sep 2, 2021
  6. cojenco
    added 2 commits that reference this issue on Oct 13, 2021

    chore: unbundle renovate reports (googleapis#575)

    This issue will close once commit e05151d is merged into the 'main' branch.
    e05151d

    chore: unbundle renovate reports (googleapis#575)

    This issue will close once commit 11b92c8 is merged into the 'main' branch.
    11b92c8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    api: storageIssues related to the googleapis/python-storage API.type: processA process-related concern. May include testing, release, or the like.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      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.