honeybadger-io / honeybadger-python

Send Python and Django errors to Honeybadger.
https://www.honeybadger.io/
MIT License
15 stars 25 forks source link

WSGIRequest has no PUT and DELETE in Django Middleware #64

Closed lfx closed 3 years ago

lfx commented 3 years ago

Hello badges, It seems that WSGIRequest don't have PUT and DELETE attributes, thus following line fails with fire https://github.com/honeybadger-io/honeybadger-python/blob/6cbec82c2d0c97587ca7d94bef31be4510fa64ec/honeybadger/contrib/django.py#L84

I'm not expert on Django, and cannot find better description then mentioned in https://stackoverflow.com/a/43171303 here.

joshuap commented 3 years ago

Thanks for reporting, @lfx.

From the Stack Overflow example:

curl -X PUT -H "Content-Type: application/json" -d '{"connid":"12"}' "127.0.0.1:8000/api/kill"

Need to reproduce and verify, then fix. The params should be included for PUT/PATCH/DELETE requests (like they are for GET/POST).

joshuap commented 3 years ago

Fixed in #65, released in 0.4.2!