-
-
Notifications
You must be signed in to change notification settings - Fork 191
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
Details for after_send_event callback are incorrect #342
Comments
Thanks for opening this issue! That information would be very helpful and should be there. I'll take a look. |
The biggest blocker I see with this—and why I opened an issue rather than a PR—is that with retries, the previous error is lost meaning that only |
Ah, right. Will take a bit of work, but it's information that should be available. |
I've opened #354 to resolve this issue, but it changes the return type, so it may warrant a new major version? |
This looks good to me, and I agree that it’s probably worth a major bump because anyone who has implemented an |
closed in #372 |
Environment
Description
The description of the
:after_send_event
callback appears to be incorrect:The spec for
maybe_call_after_send_event/2
is@spec maybe_call_after_send_event(send_event_result, Event.t()) :: Event.t()
, and@type send_event_result :: {:ok, Task.t() | String.t() | pid()} | :error | :unsampled
. So an event result of:error
includes no information related to why the event failed.Part of the reason I implemented #334 was so that I could switch Sentry logging to
:debug
and specifically suppress logging for Sentry rate-limit rejections but explicitly log other errors, such as that seen in #240 (we an alert in our ELK system for these errors, but these are currently swamped by spike protection 429s). I can’t do that with an:error
result, but would be better served by an{:error, error}
tuple result.The text was updated successfully, but these errors were encountered: