Getting an SSL error azureml

Asim Aryal 1 Reputation point
2022-06-28T16:35:18.017+00:00

I'm getting this error:

ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1131)

urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='eastus.api.azureml.ms', port=443): Max retries exceeded with url: /rp/workspaces/subscriptions/. . .

while trying to do anything with azureml sdk

from azureml.core import Workspace  
  
ws = Workspace.from_config()  
  
for compute_name in ws.compute_targets:  
    compute = ws.compute_targets[compute_name]  
    print(compute.name, ":", compute.type)  
  

How would I go about fixing this and running any kind of operation with the azureml-sdk?

Azure Machine Learning
Azure Machine Learning
An Azure machine learning service for building and deploying models.
2,583 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Ramr-msft 17,616 Reputation points
    2022-06-29T14:24:25.777+00:00

    @Asim Aryal Thanks for the question. Here is the sample notebook to run authentication in azure machine learning.

    https://github.com/Azure/MachineLearningNotebooks/blob/1f05157d24c8bd9866121b588e75dc95764ae898/how-to-use-azureml/manage-azureml-service/authentication-in-azureml/authentication-in-azureml.ipynb

    We are able to execute successfully and get the compute name and type as shown below.
    216182-image.png

    1 person found this answer helpful.
    0 comments No comments