Raygun4Python not detecting some crashes

sandlerben

Posted on
Mar 07 2017

For some reason some crashes (indicated by a 500 response) are not detected by Raygun while others are. Here is an example which was not detected by Raygun. This is from my heroku log.

Feb 21 13:44:27 clean-air-council heroku/router: at=info method=GET
path="<hidden for security>" host=clean-air-council.herokuapp.com
request_id=bb122fd1-2473-4a1d-9039-af9a055fd404 fwd="54.145.161.78"
dyno=web.1 connect=0ms service=2051ms status=500 bytes=3653

Callum

Posted on
Mar 08 2017

Thanks for raising this - we do want to capture and send as many 500s as possible so this one will be good to fix up. Are you able to provide details about your environment, including the framework/library you've built your app with, its version, and the raygun4py config code you've used to integrate the provider?

If you like, you can submit this to us privately by clicking Contact Raygun in the sidebar in the Raygun web app, and we'll pick up this ticket from there.


sandlerben

Posted on
Mar 10 2017

Yes, sure. We are using flask version 0.10.1 and raygun4py version 3.0.2. Our code is available here.

The config code is here.

We are hosting our application on Heroku.


Deleted User

Raygun

Posted on
Apr 04 2017

Hi there,

Sorry about not getting back to you sooner on this issue. We'll get someone to look into it this week for you.


Callum

Posted on
Apr 06 2017

An update on this ticket:

We've had a look into what might be the case here; currently we don't have enough data to repro this or see what is happening in the pipeline without more details e.g verbose logging or a repro request/project.

Your configuration is correct, and the Flask implementation is quite simple in that it listens for the gotrequestexception Signal that Flask triggers internally upon an exception - documented at http://flask-.readthedocs.io/en/0.6/api/#flask.gotrequestexception. If Flask doesn't provide us with the exception e.g the request dies too early or there is another issue before it hits the flask app boundary e.g a reverse proxy etc, there will be no exception to handle and send to Raygun.

If do you happen to reproduce this issue please let us know and we'll take another look.


sandlerben

Posted on
Apr 19 2017

Ok, there is definitely an error happening in the flask application that the raygun extension isn't picking up on.

First line contains heroku information, the following lines are the stacktrace. https://gist.github.com/sandlerben/7e336ff54fbeb81d88a81b80e972953f


ubermouse

Posted on
Apr 19 2017

Hi Sandler,

Can you tell me what version of Flask you are using? Looking at that stacktrace I can see it calling the self.handle_exception method inside of Flasks app.py which then forwards the exception on to the signal we are listening for in the Flask raygun4py middleware so I don't see any reason it wouldn't pick up that exception. However, I am looking at the latest code for Flask on Github so it might be different for the version you're using.


sandlerben

Posted on
Apr 24 2017

I'm using version 0.10.1.


Reply