Closed artemgordinskiy closed 5 years ago
Makes sense to me! Sounds like a great fix for error trackers
@jpetrucciani Great! Cleaned up a bit and added some tests.
@jpetrucciani Thanks for the quick merge! Could you push a new release out please? Any time this week would be great, so no rush :)
For sure! Sorry about that - meant to do that last night, but GitHub was being a bit odd. I'm surprised that it did actually merge! It kept throwing error messages when I was trying to last night. I'll get a release out soon!
Interesting - none of my Travis builds are working currently. I think it's due to the fact that GitHub is currently having some issues. I'll keep an eye out for when it's fixed, then I'll make sure Travis deploys it for us!
My bad, forgot GitHub is broken today 😄 Thanks for checking!
Just confirmed that webhooks are back to a working state, and the newest release is now live! https://pypi.org/project/hubspot3/
Awesome, thanks!
HubspotError
currently uses the following template for generating its string representation, which contains a lot of useful debugging info:However I've noticed that when using error-tracking services like Sentry, the first line of the error message is usually used as the issue title, which in this case is
---- request ----
. This leads to all of HubSpot errors being merged into one issue, making them pretty hard to track and work with.I suggest adding an error message returned from HubSpot as the first line of
__str__/__unicode__
, which would solve this problem.My implementation expects HubSpot's error responses to be returned in the following format (which seems to be the one they're using):
Haven't added any tests yet, just want to make sure it makes sense to you first.