Skip to content

Instantly share code, notes, and snippets.

@vv111y
Created October 24, 2019 19:55
Show Gist options
  • Save vv111y/c765c3c4731ae13640e2c57ee6e927d6 to your computer and use it in GitHub Desktop.
Save vv111y/c765c3c4731ae13640e2c57ee6e927d6 to your computer and use it in GitHub Desktop.
Creating a new AKS service...
---------------------------------------------------------------------------
HTTPError Traceback (most recent call last)
~/anaconda3/envs/azureml/lib/python3.7/site-packages/azureml/core/compute/compute.py in _create_compute_target(workspace, name, compute_payload, target_class)
265 try:
--> 266 resp.raise_for_status()
267 except requests.exceptions.HTTPError:
~/anaconda3/envs/azureml/lib/python3.7/site-packages/requests/models.py in raise_for_status(self)
939 if http_error_msg:
--> 940 raise HTTPError(http_error_msg, response=self)
941
HTTPError: 400 Client Error: Bad Request for url: https://management.azure.com/subscriptions/38e53cfe-df59-42bc-ac0c-b50136568522/resourceGroups/cloud-shell-storage-eastus/providers/Microsoft.MachineLearningServices/workspaces/azure-ml-ws-1/computes/aks-deployment?api-version=2019-06-01
During handling of the above exception, another exception occurred:
ComputeTargetException Traceback (most recent call last)
<ipython-input-27-4fd5439fcdb8> in <module>
3 aks_target = ComputeTarget.create(workspace = ws,
4 name = aks_name,
----> 5 provisioning_configuration = prov_config)
6 aks_target.wait_for_completion(show_output = True)
7 print(aks_target.provisioning_state)
~/anaconda3/envs/azureml/lib/python3.7/site-packages/azureml/core/compute/compute.py in create(workspace, name, provisioning_configuration)
236 " {} is a reserved name.".format(name))
237 compute_type = provisioning_configuration._compute_type
--> 238 return compute_type._create(workspace, name, provisioning_configuration)
239
240 @staticmethod
~/anaconda3/envs/azureml/lib/python3.7/site-packages/azureml/core/compute/aks.py in _create(workspace, name, provisioning_configuration)
100 compute_create_payload = AksCompute._build_create_payload(provisioning_configuration,
101 workspace.location, workspace.subscription_id)
--> 102 return ComputeTarget._create_compute_target(workspace, name, compute_create_payload, AksCompute)
103
104 @staticmethod
~/anaconda3/envs/azureml/lib/python3.7/site-packages/azureml/core/compute/compute.py in _create_compute_target(workspace, name, compute_payload, target_class)
269 'Response Code: {}\n'
270 'Headers: {}\n'
--> 271 'Content: {}'.format(resp.status_code, resp.headers, resp.content))
272 if 'Azure-AsyncOperation' not in resp.headers:
273 raise ComputeTargetException('Error, missing operation location from resp headers:\n'
ComputeTargetException: ComputeTargetException:
Message: Received bad response from Resource Provider:
Response Code: 400
Headers: {'Cache-Control': 'no-cache', 'Pragma': 'no-cache', 'Content-Length': '306', 'Content-Type': 'application/json', 'Expires': '-1', 'x-ms-correlation-request-id': 'ba835251-bf44-41a0-911e-8bc823e91ab2', 'x-ms-ratelimit-remaining-subscription-writes': '1199', 'Request-Context': 'appId=cid-v1:2d2e8e63-272e-4b3c-8598-4ee570a0e70d', 'x-ms-client-request-id': '26543cd0-b4aa-44e8-a21a-c88138621f1d', 'x-ms-client-session-id': 'f119d9ec-0dc5-4c05-8861-01db5d893728', 'x-ms-request-id': '|0594d5aa3c1c9c4eb9492cab366b853d.578d5cd2_1.3a53da2c_', 'Strict-Transport-Security': 'max-age=31536000; includeSubDomains', 'x-ms-routing-request-id': 'CANADAEAST:20191024T195421Z:ba835251-bf44-41a0-911e-8bc823e91ab2', 'X-Content-Type-Options': 'nosniff', 'Date': 'Thu, 24 Oct 2019 19:54:21 GMT'}
Content: b'{"code":"BadRequest","message":"The request is invalid","error":{"code":"BadRequest","statusCode":400,"message":"The request is invalid","details":[{"code":"BadRequestFormat","message":"A compute with the same name already exists. Updating property: provisioningState for compute is not supported yet."}]}}'
InnerException None
ErrorResponse
{
"error": {
"message": "Received bad response from Resource Provider:\nResponse Code: 400\nHeaders: {'Cache-Control': 'no-cache', 'Pragma': 'no-cache', 'Content-Length': '306', 'Content-Type': 'application/json', 'Expires': '-1', 'x-ms-correlation-request-id': 'ba835251-bf44-41a0-911e-8bc823e91ab2', 'x-ms-ratelimit-remaining-subscription-writes': '1199', 'Request-Context': 'appId=cid-v1:2d2e8e63-272e-4b3c-8598-4ee570a0e70d', 'x-ms-client-request-id': '26543cd0-b4aa-44e8-a21a-c88138621f1d', 'x-ms-client-session-id': 'f119d9ec-0dc5-4c05-8861-01db5d893728', 'x-ms-request-id': '|0594d5aa3c1c9c4eb9492cab366b853d.578d5cd2_1.3a53da2c_', 'Strict-Transport-Security': 'max-age=31536000; includeSubDomains', 'x-ms-routing-request-id': 'CANADAEAST:20191024T195421Z:ba835251-bf44-41a0-911e-8bc823e91ab2', 'X-Content-Type-Options': 'nosniff', 'Date': 'Thu, 24 Oct 2019 19:54:21 GMT'}\nContent: b'{\"code\":\"BadRequest\",\"message\":\"The request is invalid\",\"error\":{\"code\":\"BadRequest\",\"statusCode\":400,\"message\":\"The request is invalid\",\"details\":[{\"code\":\"BadRequestFormat\",\"message\":\"A compute with the same name already exists. Updating property: provisioningState for compute is not supported yet.\"}]}}'"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment