-
-
Notifications
You must be signed in to change notification settings - Fork 206
Description
Environment
- Elixir version (elixir -v): any
- Erlang/OTP version (erl): any
- Sentry version (mix deps): any
- Operating system: any
Description
The current implementation of args_from_stacktrace/1
in Sentry.Event
causes the output of inspects for stacktrace arguments to be limited and in a non-pretty format. This becomes obvious if your stacktrace is long and contains information you don't want omitted due to the default inspection limit.
:limit - limits the number of items that are printed for tuples, bitstrings, maps, lists and any other collection of items.
It does not apply to strings nor charlists and defaults to 50.
If you don't want to limit the number of items to a particular number, use :infinity.
Source: Inspect.Opts docs
Expected Behavior
To show the full stacktrace regardless of its size, and preferably in a beautiful format
Actual Behavior
Truncates the stacktrace by default due to inspect
's default limitation, and for the same default settings of inspect
, the stacktrace is not pretty-formatted
Steps to Reproduce
Try to log a long stack trace that surpasses inspect
's limit stated in the docs referenced above, and you'll get the extra stackrace omitted
Suggested Fix
Explicitly, set the options of inspect/2
as:
limit: :infinity
pretty: true
structs: false
width: 0