[Bug] az devops invoke doesn't support preview API versions
See original GitHub issueDescribe the bug I was trying to discover feed ids for our projects (since the feed ids I have to use for yaml pipelines aren’t easily discoverable) using the CLI, but it doesn’t support the preview API version I need: GET https://feeds.dev.azure.com/{organization}/{project}/_apis/packaging/feeds?api-version=5.1-preview.1
To Reproduce Azure Cli Version: 2.0.76 Azure-Devops extension version: 0.17.0
Steps to reproduce the behavior: Try to invoke a preview API, for example:
az devops invoke --organization "https://feeds.dev.azure.com/{organization}/{project}" --area packaging --resource feeds --api-version "5.1-preview.1"
View the output:
could not convert string to float: '5.1.1'
Additional context
The invoke command appears to be trying to convert the api-version
into a float, even though it should just be left as a string.
Also, the invoke command also appears to be missing several URL parameters from the documented form: VERB https://{instance}[/{team-project}]/_apis[/{area}]/{resource}?api-version={version}
. For example, team-project
is necessary now for packaging, and I’m not sure if feeds.
should be part of the {instance}
or not. It would also be nice if I could just provide a full API url and have az devops invoke
provide authentication for that url.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:2
- Comments:9 (1 by maintainers)
Top GitHub Comments
Issue is not solved. I am facing the same issue:
ERROR: could not convert string to float: '6.0.4'
Calling: https://dev.azure.com/{orgName}/_apis/serviceendpoint/endpoints?api-version=6.0-preview.4
Please consider re-opening this issue as the bug is still present with azure-cli 2.37.0 & azure-devops 0.25.0
I’ve also reported this at Visual Studio Feedback: https://developercommunity.visualstudio.com/t/az-devops-invoke-doesnt-support-preview/10077588?space=21&entry=problem&q=devops+invoke