29 Jan 2018
03:41 AM
- last edited on
19 May 2023
12:27 AM
by
Michal_Gebacki
Hi guys,
When using https://github.com/Dynatrace/dynatrace-api/blob/ma... (after adding the right url and token) got the follows error: "SSL certificate problem: unable to get local issuer certificate"
Any suggestions?
Yos
Solved! Go to Solution.
Hi Yos,
From the PyCurl error in your screenshot it seems the local CA bundle python is using on your system is outdated. If you try executing an API request from curl on the command line, does it work? I did a quick internet search for "pycurl error 60" and the first few results point to using
curl.setopt(pycurl.CAINFO,...)
to set the path to an updated system CA bundle. You would add this right before line 24, c.perform()
. Alternatively, it looks like you can utilize the python package certifi for an updated bundle local to python. Please reach back out if that doesn't work for you.
Best regards,
Lucas Hocker
Sales Engineer
Dynatrace
Had some time and changed the pycurl into requests and its works like a charm.
Also added the ability to send env id and token as parameters.
Python file is attached here as txt file
HTH
Yos
Featured Posts