microsoft / azuredevopslabs

Learn how you can plan smartly, collaborate better, and ship faster with a set of modern development services with Azure DevOps.
https://www.azuredevopslabs.com
MIT License
806 stars 903 forks source link

Error on the Create or Get Workspace step #611

Open gxgrammatikos opened 2 years ago

gxgrammatikos commented 2 years ago

I have published the "Enabling CI/CD for Machine Learning project with Azure Pipelines" template but, it crashes on the "Create or attack workspace" step. I have tried to change the Python version and the install_requirements.sh the pip install azure-cli==2.0.69 line.

Please check the raw log below:

2022-01-21T21:04:47.2506889Z ##[section]Starting: Create or Get Workspace 2022-01-21T21:04:47.2519950Z ============================================================================== 2022-01-21T21:04:47.2520264Z Task : Azure CLI 2022-01-21T21:04:47.2520647Z Description : Run Azure CLI commands against an Azure subscription in a Shell script when running on Linux agent or Batch script when running on Windows agent. 2022-01-21T21:04:47.2521021Z Version : 1.164.0 2022-01-21T21:04:47.2521224Z Author : Microsoft Corporation 2022-01-21T21:04:47.2521544Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/deploy/azure-cli 2022-01-21T21:04:47.2521900Z ============================================================================== 2022-01-21T21:04:47.4074925Z [command]/opt/hostedtoolcache/Python/3.6.15/x64/bin/az --version 2022-01-21T21:04:49.4817658Z azure-cli 2.0.69 2022-01-21T21:04:49.4818033Z 2022-01-21T21:04:49.4818490Z command-modules-nspkg 2.0.3 2022-01-21T21:04:49.4819123Z core 2.0.69 2022-01-21T21:04:49.4819405Z nspkg 3.0.4 2022-01-21T21:04:49.4819699Z telemetry 1.0.6 2022-01-21T21:04:49.4819840Z 2022-01-21T21:04:49.4820048Z Extensions: 2022-01-21T21:04:49.4820475Z azure-devops 0.22.0 2022-01-21T21:04:49.4820621Z 2022-01-21T21:04:49.4821057Z Python location '/opt/hostedtoolcache/Python/3.6.15/x64/bin/python' 2022-01-21T21:04:49.4821708Z Extensions directory '/opt/az/azcliextensions' 2022-01-21T21:04:49.4821858Z 2022-01-21T21:04:49.4822142Z Python (Linux) 3.6.15 (default, Sep 6 2021, 07:07:23) 2022-01-21T21:04:49.4822451Z [GCC 9.3.0] 2022-01-21T21:04:49.4822547Z 2022-01-21T21:04:49.4822802Z Legal docs and information: aka.ms/AzureCliLegal 2022-01-21T21:04:49.4822958Z 2022-01-21T21:04:49.4823037Z 2022-01-21T21:04:49.4824609Z Setting AZURE_CONFIG_DIR env variable to: /home/vsts/work/_temp/.azclitask 2022-01-21T21:04:49.4825894Z Setting active cloud to: AzureCloud 2022-01-21T21:04:49.4833559Z [command]/opt/hostedtoolcache/Python/3.6.15/x64/bin/az cloud set -n AzureCloud 2022-01-21T21:04:49.4834179Z WARNING: Unable to check if your CLI is up-to-date. Check your internet connection. 2022-01-21T21:04:50.2321934Z ERROR: Error loading command module 'acr' 2022-01-21T21:04:50.2344998Z [command]/opt/hostedtoolcache/Python/3.6.15/x64/bin/az login --service-principal -u --password= --tenant * 2022-01-21T21:04:50.2348306Z ERROR: Error loading command module 'ams' 2022-01-21T21:04:50.2348792Z ERROR: Error loading command module 'appconfig' 2022-01-21T21:04:50.2349226Z ERROR: Error loading command module 'appservice' 2022-01-21T21:04:50.2349896Z ERROR: Error loading command module 'backup' 2022-01-21T21:04:50.2350913Z ERROR: Error loading command module 'botservice' 2022-01-21T21:04:50.2351733Z ERROR: Error loading command module 'configure' 2022-01-21T21:04:50.2352308Z ERROR: Error loading command module 'consumption' 2022-01-21T21:04:50.2352812Z ERROR: Error loading command module 'deploymentmanager' 2022-01-21T21:04:50.2353332Z ERROR: Error loading command module 'dla' 2022-01-21T21:04:50.2354291Z ERROR: Error loading command module 'dls' 2022-01-21T21:04:50.2354708Z ERROR: Error loading command module 'hdinsight' 2022-01-21T21:04:50.2355138Z ERROR: Error loading command module 'lab' 2022-01-21T21:04:50.2355575Z ERROR: Error loading command module 'netappfiles' 2022-01-21T21:04:50.2355994Z ERROR: Error loading command module 'network' 2022-01-21T21:04:50.2356442Z ERROR: Error loading command module 'policyinsights' 2022-01-21T21:04:50.2356894Z ERROR: Error loading command module 'reservations' 2022-01-21T21:04:50.2357698Z ERROR: Error loading command module 'search' 2022-01-21T21:04:50.2358145Z ERROR: Error loading command module 'security' 2022-01-21T21:04:50.2358590Z ERROR: Error loading command module 'servicefabric' 2022-01-21T21:04:50.2359010Z ERROR: Error loading command module 'sqlvm' 2022-01-21T21:04:50.2359432Z ERROR: Error loading command module 'vm' 2022-01-21T21:04:50.2360584Z WARNING: The 'azure-devops' extension is not compatible with this version of the CLI. 2022-01-21T21:04:50.2361050Z You have CLI core version 2.0.69 and this extension requires a min of 2.30.0. 2022-01-21T21:04:51.2129426Z ERROR: Error loading command module 'acr' 2022-01-21T21:04:51.2131150Z ERROR: Error loading command module 'ams' 2022-01-21T21:04:51.2134576Z ERROR: Error loading command module 'appconfig' 2022-01-21T21:04:51.2173457Z ##[error]Error Code: [1] 2022-01-21T21:04:51.2184366Z ERROR: Error loading command module 'appservice' 2022-01-21T21:04:51.2184969Z ERROR: Error loading command module 'backup' 2022-01-21T21:04:51.2185528Z ERROR: Error loading command module 'botservice' 2022-01-21T21:04:51.2186224Z ERROR: Error loading command module 'configure' 2022-01-21T21:04:51.2186730Z ERROR: Error loading command module 'consumption' 2022-01-21T21:04:51.2188598Z ERROR: Error loading command module 'deploymentmanager' 2022-01-21T21:04:51.2189160Z ERROR: Error loading command module 'dla' 2022-01-21T21:04:51.2189665Z ERROR: Error loading command module 'dls' 2022-01-21T21:04:51.2190137Z ERROR: Error loading command module 'hdinsight' 2022-01-21T21:04:51.2190623Z ERROR: Error loading command module 'lab' 2022-01-21T21:04:51.2191113Z ERROR: Error loading command module 'netappfiles' 2022-01-21T21:04:51.2191920Z ERROR: Error loading command module 'network' 2022-01-21T21:04:51.2192447Z ERROR: Error loading command module 'policyinsights' 2022-01-21T21:04:51.2193139Z ERROR: Error loading command module 'reservations' 2022-01-21T21:04:51.2193631Z ERROR: Error loading command module 'search' 2022-01-21T21:04:51.2194135Z ERROR: Error loading command module 'security' 2022-01-21T21:04:51.2194669Z ERROR: Error loading command module 'servicefabric' 2022-01-21T21:04:51.2195158Z ERROR: Error loading command module 'sqlvm' 2022-01-21T21:04:51.2195650Z ERROR: Error loading command module 'vm' 2022-01-21T21:04:51.2196380Z WARNING: The 'azure-devops' extension is not compatible with this version of the CLI. 2022-01-21T21:04:51.2197455Z You have CLI core version 2.0.69 and this extension requires a min of 2.30.0. 2022-01-21T21:04:51.2197967Z ERROR: The command failed with an unexpected error. Here is the traceback: 2022-01-21T21:04:51.2198193Z 2022-01-21T21:04:51.2200900Z ERROR: 'BasicTokenAuthentication' object has no attribute 'get_token' 2022-01-21T21:04:51.2201292Z Traceback (most recent call last): 2022-01-21T21:04:51.2202147Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/knack/cli.py", line 231, in invoke 2022-01-21T21:04:51.2202771Z cmd_result = self.invocation.execute(args) 2022-01-21T21:04:51.2203902Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 578, in execute 2022-01-21T21:04:51.2204386Z raise ex 2022-01-21T21:04:51.2205421Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 636, in _run_jobs_serially 2022-01-21T21:04:51.2205946Z results.append(self._run_job(expanded_arg, cmd_copy)) 2022-01-21T21:04:51.2206981Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 629, in _run_job 2022-01-21T21:04:51.2207415Z six.reraise(sys.exc_info()) 2022-01-21T21:04:51.2207997Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/six.py", line 719, in reraise 2022-01-21T21:04:51.2208349Z raise value 2022-01-21T21:04:51.2208962Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 606, in _run_job 2022-01-21T21:04:51.2209796Z result = cmd_copy(params) 2022-01-21T21:04:51.2210476Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 305, in call 2022-01-21T21:04:51.2210936Z return self.handler(args, kwargs) 2022-01-21T21:04:51.2211624Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/init.py", line 485, in default_command_handler 2022-01-21T21:04:51.2212226Z return op(command_args) 2022-01-21T21:04:51.2213564Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/command_modules/profile/custom.py", line 133, in login 2022-01-21T21:04:51.2214084Z use_cert_sn_issuer=use_cert_sn_issuer) 2022-01-21T21:04:51.2215648Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 204, in find_subscriptions_on_login 2022-01-21T21:04:51.2216507Z username, sp_auth, tenant, self._ad_resource_uri) 2022-01-21T21:04:51.2217680Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 816, in find_from_service_principal_id 2022-01-21T21:04:51.2218209Z result = self._find_using_specific_tenant(tenant, token_entry[_ACCESS_TOKEN]) 2022-01-21T21:04:51.2218973Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 864, in _find_using_specific_tenant 2022-01-21T21:04:51.2219456Z for s in subscriptions: 2022-01-21T21:04:51.2220084Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/paging.py", line 129, in next 2022-01-21T21:04:51.2220519Z return next(self._page_iterator) 2022-01-21T21:04:51.2221154Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/paging.py", line 76, in next 2022-01-21T21:04:51.2221600Z self._response = self._get_next(self.continuation_token) 2022-01-21T21:04:51.2222421Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/mgmt/resource/subscriptions/v2016_06_01/operations/_subscriptions_operations.py", line 224, in get_next 2022-01-21T21:04:51.2223239Z pipeline_response = self._client._pipeline.run(request, stream=False, kwargs) 2022-01-21T21:04:51.2224112Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 211, in run 2022-01-21T21:04:51.2224607Z return first_node.send(pipeline_request) # type: ignore 2022-01-21T21:04:51.2225321Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send 2022-01-21T21:04:51.2225778Z response = self.next.send(request) 2022-01-21T21:04:51.2226575Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send 2022-01-21T21:04:51.2227014Z response = self.next.send(request) 2022-01-21T21:04:51.2227687Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send 2022-01-21T21:04:51.2228139Z response = self.next.send(request) 2022-01-21T21:04:51.2228435Z [Previous line repeated 2 more times] 2022-01-21T21:04:51.2229754Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/mgmt/core/policies/_base.py", line 47, in send 2022-01-21T21:04:51.2230367Z response = self.next.send(request) 2022-01-21T21:04:51.2231240Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_redirect.py", line 158, in send 2022-01-21T21:04:51.2232023Z response = self.next.send(request) 2022-01-21T21:04:51.2233280Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_retry.py", line 445, in send 2022-01-21T21:04:51.2233783Z response = self.next.send(request) 2022-01-21T21:04:51.2234904Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_authentication.py", line 117, in send 2022-01-21T21:04:51.2235638Z self.on_request(request) 2022-01-21T21:04:51.2236552Z File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_authentication.py", line 94, in on_request 2022-01-21T21:04:51.2237236Z self._token = self._credential.get_token(*self._scopes) 2022-01-21T21:04:51.2237984Z AttributeError: 'BasicTokenAuthentication' object has no attribute 'get_token' 2022-01-21T21:04:51.2238476Z WARNING: 2022-01-21T21:04:51.2238909Z To open an issue, please run: 'az feedback' 2022-01-21T21:04:51.2239776Z ##[error]Error: Azure login failed 2022-01-21T21:04:51.2260817Z ##[error]Script failed with error: ERROR: Error loading command module 'acr' ERROR: Error loading command module 'ams' ERROR: Error loading command module 'appconfig' ERROR: Error loading command module 'appservice' ERROR: Error loading command module 'backup' ERROR: Error loading command module 'botservice' ERROR: Error loading command module 'configure' ERROR: Error loading command module 'consumption' ERROR: Error loading command module 'deploymentmanager' ERROR: Error loading command module 'dla' ERROR: Error loading command module 'dls' ERROR: Error loading command module 'hdinsight' ERROR: Error loading command module 'lab' ERROR: Error loading command module 'netappfiles' ERROR: Error loading command module 'network' ERROR: Error loading command module 'policyinsights' ERROR: Error loading command module 'reservations' ERROR: Error loading command module 'search' ERROR: Error loading command module 'security' ERROR: Error loading command module 'servicefabric' ERROR: Error loading command module 'sqlvm' ERROR: Error loading command module 'vm' WARNING: The 'azure-devops' extension is not compatible with this version of the CLI. You have CLI core version 2.0.69 and this extension requires a min of 2.30.0. ERROR: The command failed with an unexpected error. Here is the traceback:

ERROR: 'BasicTokenAuthentication' object has no attribute 'get_token' Traceback (most recent call last): File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/knack/cli.py", line 231, in invoke cmd_result = self.invocation.execute(args) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 578, in execute raise ex File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 636, in _run_jobs_serially results.append(self._run_job(expanded_arg, cmd_copy)) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 629, in _run_job six.reraise(sys.exc_info()) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/six.py", line 719, in reraise raise value File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 606, in _run_job result = cmd_copy(params) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 305, in call return self.handler(args, kwargs) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/init.py", line 485, in default_command_handler return op(command_args) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/command_modules/profile/custom.py", line 133, in login use_cert_sn_issuer=use_cert_sn_issuer) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 204, in find_subscriptions_on_login username, sp_auth, tenant, self._ad_resource_uri) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 816, in find_from_service_principal_id result = self._find_using_specific_tenant(tenant, token_entry[_ACCESS_TOKEN]) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/cli/core/_profile.py", line 864, in _find_using_specific_tenant for s in subscriptions: File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/paging.py", line 129, in next return next(self._page_iterator) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/paging.py", line 76, in next self._response = self._get_next(self.continuation_token) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/mgmt/resource/subscriptions/v2016_06_01/operations/_subscriptions_operations.py", line 224, in get_next pipeline_response = self._client._pipeline.run(request, stream=False, *kwargs) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 211, in run return first_node.send(pipeline_request) # type: ignore File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send response = self.next.send(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send response = self.next.send(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/_base.py", line 71, in send response = self.next.send(request) [Previous line repeated 2 more times] File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/mgmt/core/policies/_base.py", line 47, in send response = self.next.send(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_redirect.py", line 158, in send response = self.next.send(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_retry.py", line 445, in send response = self.next.send(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_authentication.py", line 117, in send self.on_request(request) File "/opt/hostedtoolcache/Python/3.6.15/x64/lib/python3.6/site-packages/azure/core/pipeline/policies/_authentication.py", line 94, in on_request self._token = self._credential.get_token(self._scopes) AttributeError: 'BasicTokenAuthentication' object has no attribute 'get_token' WARNING: To open an issue, please run: 'az feedback'

2022-01-21T21:04:51.2275399Z ##[section]Finishing: Create or Get Workspace