Uploaded image for project: 'Project Quay'
  1. Project Quay
  2. PROJQUAY-9346

ProxyCache with public repositories are broken since commit ed70eff7522c709699e8b91289f606213d4404fe

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done-Errata
    • Icon: Critical Critical
    • quay-v3.15.2
    • quay-v3.13.7, quay-v3.14.4, quay-v3.15.6
    • quay
    • False
    • Hide

      None

      Show
      None
    • False
    • User Experience
    • Low

      Reproducer:

      • quay-operator.v3.13.7
      • ProxyCache Organization
        • public accessible repositories

       

      Once a Repository in an ProxyCache Organization is set to public access, the code commited with Download blob not cached when pulling manifests with blobs available locally (PROJQUAY-6708) assumes that there is always a user by calling 

      queue_id = proxy_cache_blob_queue.put(
                      [self._user.username, str(repo_id), str(layer.digest)],
                      json.dumps(
                          {
                              "digest": str(layer.digest),
                              "repo_id": repo_id,
                              "username": self._user.username,
                              "namespace": self._user.username,
                          }
                      ),
                      available_after=5,
                  ) 

      where self._user.username get's decorated with get_authenticated_user in ./endpoints/decorators.py  from the auth flask framework.

      The code needs to ensure that if set to public access the  _user = None object is not evaluated for the username attribute.

       

      I also want to encourage that we get this in the QE process as well.

        1. Screenshot 2025-09-04 at 22.27.29.png
          241 kB
          Weihua Hu
        2. Screenshot 2025-09-04 at 22.25.53.png
          235 kB
          Weihua Hu
        3. image-2025-08-28-14-27-52-961.png
          286 kB
          luffy zhang

              bcaton@redhat.com Brandon Caton
              rhn-support-milang Michaela Lang
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated:
                Resolved: