Azure / azure-cli

Azure Command-Line Interface
MIT License
3.92k stars 2.89k forks source link

az datafactory pipeline list fails with parse error for large number of pipelines #27563

Open rmartin-msft opened 9 months ago

rmartin-msft commented 9 months ago

Describe the bug

When using the commands az datafactory pipeline list to return a list of the pipelines associated with an Azure Data Factory the command will return a JSON parser error when there are a large number of pipelines associated with the data factory.

Related command

az datafactory pipeline list

Errors

InnerException : False Exception : Microsoft.Rest.SerializationException: Unable to deserialize the response. ---> Newtonsoft.Json.JsonReaderException: Error reading boolean. Unexpected token: StartObject. Path 'enablePartitionDiscovery', line 11090, position 63. at Newtonsoft.Json.JsonReader.ReadAsBoolean() at Newtonsoft.Json.JsonReader.ReadForType(JsonContract contract, Boolean hasConverter) at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType,

Issue script & Debug output

az datafactory pipeline list

Expected behavior

JSON response

Environment Summary

azure-cli: 2.52.0 azure-cli-core: 2.52.0 azure-cli-telemetry: 1.1.0

extensions: account: 0.2.5 aks-preview: 0.5.156 azure-devops: 0.26.0 containerapp: 0.3.39 datafactory: 0.7.0 devcenter: 2.0.0 resource-graph: 2.1.0

Additional context

This appears to be because the command does not properly handle the situation where the underlying REST API response is paginated. To test this you can use az rest and note that the API returns only part of the data and indicated that there is more to follow.

azure-client-tools-bot-prd[bot] commented 9 months ago

Hi @rmartin-msft,

2.52.0 is not the latest Azure CLI(2.53.0).

If you haven't already attempted to do so, please upgrade to the latest Azure CLI version by following https://learn.microsoft.com/en-us/cli/azure/update-azure-cli.

yonzhan commented 9 months ago

Thank you for opening this issue, we will look into it.

microsoft-github-policy-service[bot] commented 9 months ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @zhangyd2015, @Frey-Wang, @Jingshu923.

microsoft-github-policy-service[bot] commented 9 months ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @zhangyd2015, @Frey-Wang, @Jingshu923.

rmartin-msft commented 8 months ago

Has there been any update on this ibug?