-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Logger omits unexpected exception during pretty printing, hindering issue diagnosis and resolution #10201
Comments
I'll be happy to help resolve this bug. I'll present a solution on how to fix this bug tomorrow. |
hqdncw
added a commit
to hqdncw/dvc
that referenced
this issue
Dec 27, 2023
Fixes iterative#10201 Signed-off-by: hqdncw <hqdncw@gmail.com>
2 tasks
hqdncw
added a commit
to hqdncw/dvc
that referenced
this issue
Dec 27, 2023
Fixes iterative#10201 Signed-off-by: hqdncw <hqdncw@gmail.com>
hqdncw
added a commit
to hqdncw/dvc
that referenced
this issue
Dec 27, 2023
Fixes iterative#10201 Signed-off-by: hqdncw <hqdncw@gmail.com>
Closing, this is intentional. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Report
Description
The logger in
dvc/logger.py
incorrectly handles exceptions that occur during the process of pretty printing error messages. Specifically, when an unexpected exception occurs, the logger fails to include the exception in the log output, resulting in incomplete traceback. This makes it difficult to diagnose issues and understand the root cause of problems.Reproduce
Replace the following lines in
dvc/logger.py
:dvc/dvc/logger.py
Lines 147 to 153 in 27a8222
with the following code:
Initialize a DVC project
dvc repro
command with the--verbose
flag turned on, like so:Actual output
Expected
Traceback that includes the unexpected error, like so:
Expected output
Output of
dvc doctor
:Additional Information (if any):
18 tests in the
tests/func/utils/test_strict_yaml.py
file are considered flaky because they consistently report a passing result, even when a RuntimeError is intentionally triggered during the emitting of pretty exceptions.Related: #9704, #10110 (comment), #10110 (comment)
The text was updated successfully, but these errors were encountered: