azure-devops-cli-extension icon indicating copy to clipboard operation
azure-devops-cli-extension copied to clipboard

[Bug] az pipelines release list lists only the first 100 releases

Open davidhabibi opened this issue 5 years ago • 5 comments

az pipelines release list lists only the first 100 releases regardless of --top 1000 option

To @Reproduce Azure Cli Version: azure-cli 2.0.78 *

Azure-Devops extension version: azure-devops 0.16.0

Steps to reproduce the behavior:

  1. login using az login
  2. setup variables $organization and $project to match a project with over 100 deployments
  3. Run command: az pipelines release list --org $organization --project $project --top 1000 -o table | Measure-Object -Line It returns 102 lines (100 releases +2 lines of header)

Expected behavior It should return N+2 lines (N releases over 100 +2 lines of header)

Screenshots az pipelines release list

Debug logs I cannot do that - private data

Additional context Already reported in the wrong thread by someone else. The issue was then closed by @fengzhou-msft. https://github.com/Azure/azure-cli/issues/11256

davidhabibi avatar Jan 16 '20 15:01 davidhabibi

The support for continuation token was missing in the older client (5.0/5.1). This got fixed in the 6.0 client. This affects a lot of list commands including the one you pointed out here. We will upgrade the client dependency to fix this (currently the version 6.0 is in preview, so it could be a while).

Would having one of the filters (like release-id) help you or you want to list out all the releases always?

atbagga avatar Jan 21 '20 08:01 atbagga

I found a workaround using --definition-id option. This should be fine for a while as for each pipeline we have less than 100 release deployed.

davidhabibi avatar Jan 21 '20 15:01 davidhabibi

@atbagga Has there been any recent work on this? I just ran into this problem today.

elesel avatar Mar 24 '22 18:03 elesel

I have this problem with test plans. The TestPlanClient [https://github.com/Azure/azure-devops-cli-extension/blob/7fc9bfc19c61876ebf7e12eb23f55b38d2bdc78e/azure-devops/azext_devops/devops_sdk/v6_0/test_plan/test_plan_client.py#L177] does not return the response headers, so it's impossible to know if a continuation token was present or not.

ron-premier avatar May 09 '23 00:05 ron-premier