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

Add backtrace to watchdog:show-one #6065

Closed
andriokha opened this issue Jul 16, 2024 · 1 comment · May be fixed by #6066
Closed

Add backtrace to watchdog:show-one #6065

andriokha opened this issue Jul 16, 2024 · 1 comment · May be fixed by #6066

Comments

@andriokha
Copy link
Contributor

Is your feature request related to a problem? Please describe.
When an exception is logged to the dblog by \Drupal\Core\EventSubscriber\ExceptionLoggingSubscriber::onError() or \Drupal\Core\Utility\Error::logException(), there is no backtrace shown when using watchdog:show-one and it is very difficult to find the problem in code.

Describe the solution you'd like
Display the backtrace as a separate field.

Additional context
The reason the issue exists is because the log message doesn't by default contain the @backtrace_string placeholder (\Drupal\Core\Utility\Error::DEFAULT_ERROR_MESSAGE is %type: @message in %function (line %line of %file).). The issue was fixed in Drupal 10.2 and 11.x here where they opted to add a new backtrace row.

@weitzman
Copy link
Member

weitzman commented Aug 2, 2024

Lets close this and keep working in the PR #6066

@weitzman weitzman closed this as completed Aug 2, 2024
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 a pull request may close this issue.

2 participants