Skip to content

new pagiantion on v3.1.0 causes tag listing to be broken when pagiantion number is greater than 1000 #4844

@viceice

Description

@viceice

Description

Renovate uses n=10000 for tags/list endpoint and distribution v3.1.0 reduced the default to 1000.
So renovate now get's a 400.

 WARN: Invalid registry response (repository=viceice-tests/docker-distribution)
       "apiCheckUrl": "https://mcr.domain.test/v2/dotnet/sdk/tags/list?n=10000",
       "res": {
         "statusCode": 400,
         "headers": {
           "content-length": "119",
           "content-type": "application/json",
           "date": "Thu, 09 Apr 2026 09:45:31 GMT",
           "docker-distribution-api-version": "registry/2.0",
           "x-content-type-options": "nosniff"
         },
         "body": {
           "errors": [
             {
               "code": "PAGINATION_NUMBER_INVALID",
               "message": "invalid number of results requested",
               "detail": {"n": 10000}
             }
           ]
         },
         "authorization": false
       }

Now i tried to set tags.maxtags=10000 but then distribution simply returns 500.

 WARN: Invalid registry response (repository=viceice-tests/docker-distribution)
       "apiCheckUrl": "https://mcr.domain.test/v2/dotnet/sdk/tags/list?n=10000",
       "res": {
         "statusCode": 500,
         "headers": {
           "content-length": "91",
           "content-type": "application/json",
           "date": "Thu, 09 Apr 2026 09:39:39 GMT",
           "docker-distribution-api-version": "registry/2.0",
           "x-content-type-options": "nosniff"
         },
         "body": {
           "errors": [
             {
               "code": "UNKNOWN",
               "message": "unknown error",
               "detail": "operation unsupported"
             }
           ]
         },
         "authorization": false
       }

Reproduce

  1. start registry v3.1.0 and configure proxy.remoteurl: https://mcr.microsoft.com
  2. run curl -sv http://registry/v2/dotnet/runtime-deps/tags/list?n=10000
  3. see 400
  4. configure tags.maxtags:10000 and restart registry
  5. run curl -sv http://registry/v2/dotnet/runtime-deps/tags/list?n=10000
  6. see 500

Expected behavior

at least when setting max tags to 10000 then it should return the list

proxy:
  remoteurl: https://mcr.microsoft.com
tags:
  # https://github.com/distribution/distribution/pull/4353
  # distribution v3.1.0 limits this to 1_000 but renovate needs 10_000
  maxtags: 10000

registry version

registry github.com/distribution/distribution/v3 3.1.0

ghcr.io/distribution/distribution:3.1.0@sha256:4fdc7c11dd6b58fd06e386971bf29929eebd831a074197ad1457a1aefeacf3da

Additional Info

it seems these PR's causes the trouble 🤔

proxyTagService returns the ErrUnsupported 😕

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions