Skip to content
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

log error stack #3630

Closed
wants to merge 3 commits into from
Closed

log error stack #3630

wants to merge 3 commits into from

Conversation

natebosch
Copy link
Member

  • Always log stack traces for Error objects
  • Fix json serializable annotation for ignored field

Closes #3585

The default logging omits stack traces by default and prints them only
in verbose mode. This is intended to allow builder implementations to
cease execution and log a user friendly message by throwing a single
`Exception` with a custom `toString()`. When a builder or utility
library has an implementation bug leading to an `Error` the stack trace
is much more likely to be useful information for debugging, and worth
including by default.
The annotation was last changed in
#3445

The intention of the change was to retain behavior of passing the
deprecated option `ignore: true`. The replacement is to use two fields
`includeToJson` and `includeFromJson` which allow more fine-grained
configuration, but also invert the condition. The boolean must be
`false` to retain old behavior.

Before this change rerunning code generation would result in a change to
`build_config.g.gdart`. After this change the build is a no-op.
@natebosch
Copy link
Member Author

I was not on a sensible branch when I opened this... I'l try again.

@natebosch natebosch closed this Dec 27, 2023
@natebosch natebosch deleted the log-error-stack branch December 27, 2023 01:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant