0

I am getting SSL error while creating any app with slack_bolt and python 3.11. When I change python version to 3.9 all works well, tried on multiple machines. Since I have to use python 3.11 in my org i am stuck with this error I have tried all solutions from internet and nothing works.

Is there any issue with SSL and slack_bolt ?

Code is pretty basic :

import os


from slack_bolt import App

from slack_bolt.adapter.socket_mode import SocketModeHandler

SLACK_BOT_TOKEN = <bot_toen>

SLACK_APP_TOKEN = <app_token>

app = App(token=SLACK_BOT_TOKEN)


if __name__ == "__main__":

SocketModeHandler(app, SLACK_APP_TOKEN).start()

Error :

Failed to send a request to Slack API server: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1002)>

Tried all solutions available on internet related to cerficates or SSL but still getting same error

toyota Supra
  • 3,181
  • 4
  • 15
  • 19
  • How about upgrading the openssl version used by the python 3.11 runtime? Perhaps, your machine may have multiple versions of openssl and 3.9 may be using a good one. Alternative approach is clean install python 3.11 and install pip packages . – Kazuhiro Sera Apr 28 '23 at 05:37
  • Thanks for replying, I have removed everything related to python and reinstalled but still no luck. Could you please try to run a small slack chatbot app and see if getting similar error and try to fix it. – Sandeep Chaudhary Apr 29 '23 at 20:13
  • 1
    I've been running Slack apps using the SDK along with python 3.11 for a while. I am sure that it's not the runtime's issue. Another try you can do is to use python's docker image and see how it goes. If you don't see the same issue with it, your local python/openssl is the cause. – Kazuhiro Sera May 01 '23 at 23:40

0 Answers0