New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SSL Certification error #334
Comments
I have run into the same exact problem today. I fixed it by downgrading the websocket-client library to 0.47.0 |
Are you both using a proxy configuration? If so, it may be that your proxy has a certificate which doesn't have a root in the CA bundle shipping with this package. If that's the case, I see two options:
|
0.48.0 of websocket-client appears to have removed the CA bundle actually which I think the problem is. I am on a Mac, I have not had the chance to test this on another OS to see if the load_default_certs for Mac is the problem. |
@KoalaTea wow, you're right, and also that's no great. it looks like websocket-client/websocket-client#413 is the issue where this decision was made. i hope the maintainers of that package will consider reversing this decision. for example, the |
i made an issue for my suggestion: websocket-client/websocket-client#451. if the maintainers indicate that they'd merge that change in, we can contribute the code. |
Also ran into this issue, not sure if work is being done to resolve this or should I just implement a hotfix to my own proj by downgrading the websocket version. |
For those of you affected, I think it would be helpful for you to express support of websocket-client/websocket-client#451. The easiest way would be click through and put a thumbsup reaction on the top comment. |
so I am still running into the same issue here, I am new to python and have tried to downgrade the websocket-client library to 0.47.0, but it still returns the same error! |
I named possible solutions in websocket-client/websocket-client#451 (comment) if you care to try. |
Hey, |
There are a couple of things that can be done: 1. Downgrading the |
This is sloved my problem..
|
I ran into this issue today and I've tried downgrading websocket-client to 0.47.0, and exported WEBSOCKET_CLIENT_CA_BUNDLE=DigiCertGlobalRootCA.crt on my system. Neither option worked. Any ideas for my system running python 3.7.2 on Ubuntu? |
@pancho-villa on Ubuntu, you may want to try |
Thanks for the heads up @aoberoi, but it didn't work. I tried it on a Fedora 29 machine as well. I found that I can monkey patch the request to add verify=False to bypass the error for now. |
Worked for me too |
Thanks for your information. I would like to know how to execute the command, thank you!
============== |
I've also found success setting the Requests or OpenSSL certificates: # https://docs.python-requests.org/en/msater/user/advanced/#ssl-cert-verification
os.environ['REQUESTS_CA_BUNDLE'] = 'YourRootCertificate.crt' # Requests
os.environ['SSL_CERT_FILE'] = 'YourRootCertificate.crt' # OpenSSL
os.environ['SSL_CERT_DIR'] = '/path/to/your/certificates/' |
Due to the fact that no changes should be made in this library I'm closing this issue. The workarounds posted above should be explored if you need to remain on v1 of this project. (i.e. You need to use Python 2.7) I'd encourage all others to take advantage of all the new features in v2 by following the migration guide. SSL configuration is better supported in v2. You can take a look at one approach to doing this with the new client in the tutorial. |
Build is still broken here with the same error...took me some time to realize it is slack related issue and not a general OS issue... |
@AlmogCohen can you provide any more details to your conclusion? I've not been able to discover any issues where the root cause is related to Slack. |
Since this package was the official one supported by slack for a long time I do have some expectations for it to work including some accountability to the dependencies it is shipped with. Maybe it is too much to expect that. If it says any Also, I did see the v2 SDK and it looks amazing...BUT it is not trivial to shift existing code bases to use it as if it is a drop-in replacement to issues with the v1 SDK. v2 is awesome, but quite different (for good, yet different) |
@AlmogCohen I understand now. Thank you for the feedback. I apologize for the frustration that was caused. I've recently taken on this project and will be leading the development efforts moving forward. Next week I'll be switching part of my focus on bug fixing v1 where it makes sense. Around this same time I'll consider locking down the If you can work with Python 3.6+ and would like to use the new v2 SDK. Please open a new issue to let me know if there's anything I can do to ease the migration efforts. |
Thank you man for the understanding and support! Good luck with project
support :)
…On Wed, May 8, 2019 at 3:19 PM Rodney Urquhart ***@***.***> wrote:
@AlmogCohen <https://github.com/AlmogCohen> I understand now. Thank you
for the feedback. I apologize for the frustration that was caused. I've
recently taken on this project and will be leading the development efforts
moving forward.
Next week I'll be switching part of my focus on bug fixing v1 where it
makes sense. Around this same time I'll consider locking down the
websocket-client version to the previous 0.47.0 version.
If you can work with Python 3.6+ and would like to use the new v2 SDK.
Please open a new issue to let me know if there's anything I can do to ease
the migration efforts.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#334 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA5VOZTMWMMVC2TK4WAP2MLPUNGVZANCNFSM4FIZ2KAQ>
.
--
Almog Cohen
<https://htmlsig.com/signatures/01ADE8F6/edit>
[image: Linkedin] <http://linkedin.com/in/almogcohen>
*US: (415) 413-6714*
|
works |
that works for me, i've seen it, the
|
How to downgrade to websocket_client 0.47.0 ? i mean what should I write in Mac terminal to get this done ? |
Depends on your package management tool - is it pipenv? Is it pip?
Depending on your tool /environment you can set the version of the package
…On Sat, Aug 24, 2019, 15:11 Omer-Khabeer ***@***.***> wrote:
How to downgrade to websocket_client 0.47.0 ? i mean what should I write
in Mac terminal to get this done ?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#334>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA5VOZSNQ2W5HRYE5HA5STTQGE6QLANCNFSM4FIZ2KAQ>
.
|
it is pip |
This is what fixed it for me. |
pip3 install websocket-client==0.47.0 |
This worked for me unlike the other proposed solutions here. |
I've also had success setting the ssl context: import urllib.request
import ssl
ssl._create_default_https_context = ssl._create_unverified_context
r = urllib.request.urlopen('https://google.com')
print(r.status)
print(r) |
None of these worked for me. I'm on a mac with python 3.10 |
Description
I've built a bot in python 3.7 using a virtual engine, when I come to run the code I get this error:
During handling of the above exception, another exception occurred:
Connection failed. Exception traceback printed above.
This seems similar to this: #325 but I tried the User's suggestion and it hasn't changed anything.
I have the bot's 'Bot User OAuth Access Token' stored as a variable which I refer to in the code
Any suggestions?
Describe your issue here.
What type of issue is this? (place an
x
in one of the[ ]
)Requirements (place an
x
in each of the[ ]
)Bug Report
Filling out the following details about bugs will help us solve your issue sooner.
Reproducible in:
slackclient version:
python version: 3.7
OS version(s):
Steps to reproduce:
Expected result:
What you expected to happen
Actual result:
What actually happened
Attachments:
Logs, screenshots, screencast, sample project, funny gif, etc.
The text was updated successfully, but these errors were encountered: