rsa16 Posted March 17, 2023 Posted March 17, 2023 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!
Kairion Posted March 17, 2023 Posted March 17, 2023 (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, 2023 by Kairion Including possible solution.
rsa16 Posted March 17, 2023 Author Posted March 17, 2023 (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, 2023 by rsa16 didn't refresh page and see the other edit
Kairion Posted March 17, 2023 Posted March 17, 2023 I am glad to know it worked. Let us know if you need help with anything else.
baongoc159 Posted June 13, 2023 Posted June 13, 2023 Hi @rsa16 I'm also creating the Bot like you. The tutorial is out of date. What need to change in that tutorial ? I only change the path to cgi-bin, from "public_html/cgi-bin" to "httpdocs/cgi-bin" But when I access ...heliohost.us/cgi-bin/start.py, it gives: Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator at root@localhost to inform them of the time this error occurred, and the actions you performed just before this error. More information about this error may be available in the server error log. Also, no log file in
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now