Azure / Azure/azure-devops-cli-extension
Variables are not created without any error output
- Dominant language
- Python
- Stars
- 682
- Forks
- 278
- Avg merge
- 3d 23h
- Merged PRs (30d)
- 3
Description
**Describe the bug**
Running `variable create` sometimes does NOT create the variable and does not produce any error. The bug is most consistently reproducible when attempting to create some number of variables at once parallely.
**To Reproduce**
- Create a variable group
- set `$env:organization` and `$env:project` in your terminal
- Run the following powershell script. It should create 100 variables numbered from 000 to 099
```pscore
$config = @{}
for ($i=0;$i -lt 100;$i++) {
$num = $i.ToString("000")
$config.Add("test_key_$($num)", "test_value_$($num)")
}
# checks, creates or overwrites all variables
$config.Keys | ForEach-Object -Parallel {
$variable_name = $_
$variable_value = ($using:config)[$_]
az pipelines variable-group variable create --group-id=67 --org="https://dev.azure.com/$($env:organization)" --project="$($env:project)" --name="$($variable_name)" --value="$($variable_value)"
} -ThrottleLimit 10
```
- The script does not produce any error (except the notification that the extension is in preview)
- Check the variable group and see that there are some variables missing.
Azure Cli Version: 2.8.0
Azure-Devops extension version: azure-devops (0.18.0)
**Expected behavior**
All variables are created in the variable group OR I get some notification error that I'm sending too many requests.
I suspect that the server is returning `HTTP 429 Too Many Requests` but the extension is just not handling it correctly when it should write an error message.
Contributor guide
Assessment
This issue has not been assessed yet.