rsa16 Posted March 17 Share Posted March 17 Hi! I have written a CGI script to start my discord bot and output any errors that may occur, and I keep getting this error: ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:997) The full traceback is at https://pastebin.com/jWBLn6x0, sorry everything has the word "line" appended before it, it was how my script outputted the log. If anyone could help that would be great! Quote Link to comment Share on other sites More sharing options...
Kairion Posted March 17 Share Posted March 17 (edited) We do have a tutorial about Discord bots, but it was written when we still used cPanel, so it may need to be adapted. Anyway, here it goes: https://wiki.helionet.org/tutorials/discord-bot Since I'm not a Python programmer, I am unable to help much further than that. EDIT: @rsa16, I talked with our staff about your case, and one of our root admins recommend that you use that code to solve your error: import certifi os.environ["SSL_CERT_FILE"] = certifi.where() Edited March 17 by Kairion Including possible solution. Quote Link to comment Share on other sites More sharing options...
rsa16 Posted March 17 Author Share Posted March 17 (edited) Yeah, that's the exact tutorial I saw. I tried to get it to work on Plesk and I got pretty far except I encountered that error, and now I'm basically clueless. I think it has something to do with an outdated certificate but I'm not sure. EDIT: Sorry, I didn't refresh my page and see your edit, thanks for the solution, I'll try and see if it works! Edited March 17 by rsa16 didn't refresh page and see the other edit Quote Link to comment Share on other sites More sharing options...
rsa16 Posted March 17 Author Share Posted March 17 Thank you so much! That works! Quote Link to comment Share on other sites More sharing options...
Kairion Posted March 17 Share Posted March 17 I am glad to know it worked. Let us know if you need help with anything else. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.