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

Include exception message when generating error report #2311

Conversation

elidrissidev
Copy link
Member

@elidrissidev elidrissidev commented Jul 12, 2022

Description (*)

Magento provides the ability to print exceptions by using Mage#printException method, which prints the exception message, the stacktrace, and any extra data provided. If Developer Mode is not active however, this information is not printed and is saved in error report files (in var/report dir). These error reports did not include the exception message if any extra data is provided, leaving out an important puzzle piece to debugging the issue.

Fixed Issues (if relevant)

  1. Fixes Lost error data on SQL error #2279

Manual testing scenarios (*)

  1. Make sure Developer Mode is disabled and purposefully trigger an exception (example in linked issue).
  2. The error report should include enough information to debug the issue, including the exception message.

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All automated tests passed successfully (all builds are green)
  • Add yourself to contributors list

@github-actions github-actions bot added the Mage.php Relates to app/Mage.php label Jul 12, 2022
@Flyingmana Flyingmana merged commit 24c8721 into OpenMage:1.9.4.x Jul 12, 2022
@github-actions
Copy link
Contributor

Unit Test Results

1 files  ±0  1 suites  ±0   0s ⏱️ ±0s
0 tests ±0  0 ✔️ ±0  0 💤 ±0  0 ❌ ±0 
7 runs  ±0  5 ✔️ ±0  2 💤 ±0  0 ❌ ±0 

Results for commit 24c8721. ± Comparison against base commit a11d247.

@elidrissidev elidrissidev deleted the improvement/error-report-additional-data branch July 12, 2022 11:10
elidrissidev added a commit to elidrissidev/magento-lts that referenced this pull request Jul 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Mage.php Relates to app/Mage.php
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lost error data on SQL error
3 participants