-
Notifications
You must be signed in to change notification settings - Fork 135
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/TLS error in Django connecting to api.rollbar.com on exceptions #215
Comments
I am testing with the debug error view, so maybe related to this? #180 . Not sure because I can't see clubhouse. |
Hi @taylor-cedar, Are you still having this issue? If so, what version of pyrollbar are you on? |
Closing due to inactivity. |
I think this issue is still valid. We are experiencing the same problem with the following setup:
I read some similar issues on other client libraries and seems like it can be related to thread (un)safety of requests's sessions. See: https://stackoverflow.com/questions/18188044/is-the-session-object-from-pythons-requests-library-thread-safe |
Mentioned in #180, but we're running django version 2.1.2 and rollbar version 0.14.5 and are still seeing a very similar traceback as mentioned above:
Other useful context might be that this code is executing in an AWS lambda function environment |
Facing the same issue while on flask. It's working fine when running on my local, but when deployed to AWS inside a docker container get an error.
|
Any update on this issue? We are facing the same problem using |
I have a hunch this may be connected with how we handle threading and sessions when transporting payloads. Because our default 'threading' handler does not reuse transport threads we throw away each new I would suggest trying our experimental |
We are running into this issue on our AWS Lambda environment as well. Unfortunately, @danielmorell 's suggestion above of upgrading to I noticed in my internal testing that I was only able to reproduce the bug when reporting to Rollbar from multiple lambda instances concurrently (though I'm not sure if the concurrency, the higher volume of requests in a short period, or something else entirely is the cause). Our solution for now is to override |
We're also running into this issue in AWS lambda. The lambda runs 1x/daily with a reserved concurrency of 1. |
@danielmorell Isaac created a batched transformer that might be able to resolve this issue. Can you look into it to see if it could resolve this issue? It was this PR: #421 |
@rollbar-bborsits This seems like it has to do with the transport process but probably not the serialization and scrubbing process. |
@danielmorell Do you need more info to debug this issue? |
We've also been frequently experiencing these SSL errors with Flask (only when deployed to AWS inside a docker container), but setting We're running |
Also getting this error on a Wagtail/Django deployment on AWS App Runner. Does not happen on a standard EC2 deployment.
|
This error is not caused by the Python Rollbar SDK. It likely comes from the SSL implementation available to requests, or from a networking issue between your server, and the Rollbar backend. I would recommend reading this issue psf/requests#3605 for some context from the maintainers of requests. I won't restate everything in that issue thread. However, one important take away is that if the issue is intermittent, it is likely a networking issue. If it is consistent, you may want to check the version of OpenSSL as well as the rest of your networking dependencies. Lastly, the final error is thrown when the max retries is exceeded. If this is being throw intermittently, we could add a config option to silence these exceptions, and possibly write them to an agent file. What are everyone's thoughts on this? |
A config option to prevent pyrollbar exceptions from interrupting the application sounds good. Perhaps instead of silencing, if it's possible to write to the root python logger / stderr handler, while avoiding recursive logging by the rollbar handler itself? The idea is to preserve visibility into pyrollbar problems -- e.g. visible as warnings in AWS cloudwatch logs. Thank you. |
This error happens for about 2 out of every 3 requests to send an exception to rollbar. It occasionally works, but mostly doesn't. The following stack trace is printed only occasionally. Sometimes it will fail with no exception stack trace.
Python 3.6.1
Django 1.11.1
uwsgi 2.0.14
requests 2.18.4
open-ssl 1.0.2k 26 Jan 2017
Docker Alpine Linux
Please let me know if I can provide more info. It seems like some kind of race condition, but not sure, since it sometimes works. Maybe it's a thread safety issue?
The text was updated successfully, but these errors were encountered: