az artifacts universal download fails with Access denied and file not found
See original GitHub issueThis is autogenerated. Please review and update as needed.
Describe the bug
Command Name
az artifacts universal download Extension Name: azure-devops. Version: 0.12.0.
Errors:
First error when using verbose logging:
An error occurred while extracting the Universal Packages tooling: [WinError 5] Access is denied: 'C:\\Users\\WS19312\\.azure\\azuredevops\\cli\\tools\\artifacttool\\a445ec82-2166-4964-946e-d868ead0c4e3' -> 'C:\\Users\\WS19312\\.azure\\azuredevops\\cli\\tools\\artifacttool\\ArtifactTool_win10-x64_0.2.104'
Error trace reported by tool:
[WinError 2] The system cannot find the file specified
Traceback (most recent call last):
pip-install-76yvurxi\knack\knack\cli.py, ln 206, in invoke
cli\core\commands\__init__.py, ln 575, in execute
cli\core\commands\__init__.py, ln 633, in _run_jobs_serially
cli\core\commands\__init__.py, ln 624, in _run_job
azext_devops\dev\common\exception_handler.py, ln 26, in azure_devops_exception_handler
reraise(*sys.exc_info())
Temp\pip-install-76yvurxi\six\six.py, ln 693, in reraise
cli\core\commands\__init__.py, ln 603, in _run_job
...
Azure\CLI2\lib\subprocess.py, ln 709, in __init__
restore_signals, start_new_session)
Azure\CLI2\lib\subprocess.py, ln 997, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
az login
az extension add --name azure-DevOps
az artifacts universal download --organization {} --feed {} --name {} --version {} --path {} --debug
Expected Behavior
Environment Summary
Windows-10-10.0.16299-SP0
Python 3.6.6
Shell: powershell.exe
azure-cli 2.0.68 *
Extensions:
azure-devops 0.12.0
Additional Context
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:24 (5 by maintainers)
Top Results From Across the Web
New tokens don't work with artifacts repository
I'm unable to download or upload artifacts from/to the Artifacts repository ... Failed to update Universal Packages tooling. Access Denied:.
Read more >Release notes & updates – Azure CLI - Microsoft Learn
Learn about the latest Azure Command-Line Interface (CLI) release notes and updates for both the current and beta versions of the CLI.
Read more >Cant download azure artifacts through service principal
I am trying to fetch Azure Artifacts through Service Principal in PowerShell but not able to do it. Reproduction step: az login ...
Read more >Troubleshooting | Cloud Storage
Attempting to use an authenticated browser download for non-public objects results in a 403 response. This restriction exists to prevent phishing for Google...
Read more >Bug listing with status RESOLVED with resolution OBSOLETE ...
systemPrefs with at least two files" status:RESOLVED resolution:OBSOLETE severity:normal ... failed to emerge with permission denied" status:RESOLVED ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve got it working by obtaining the binary ArtifactTool_win10-x64_0.2.128 (via a less secure Windows system) and placing it into the correct directory manually. Another person in my org used the --debug data to identify the .zip and manually download the zip and do the same thing.
I suspect @marklindell would have success by running the az command again with the --debug flag, capture the output, find the line with “ArtifactTool”, grab that URL, download with curl (or maybe a browser), unzip the contents into USER/.azure/azuredevops/cli/tools/artifacttool/ArtifactTool_win10-x64_0.2.128 (or whatever the zip file root name is).
No idea why I have to do this, but I think there is behind the scenes security software involved.
The fix was to add retries to the file handling and adding additional logging to get more information out of this error. If you are using azure devops extension 0.17.0 and still seeing the issue then please paste the detailed logs and we can investigate this further.
@atbagga Let’s keep this open for now and we will check the new logs to determine if this is the same issue or not.
Adding @satbai as well.