-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Improve error logging with a stacktrace #1458
base: main
Are you sure you want to change the base?
Conversation
Hi @severi Thanks for the contribution! Is it possible to make this configurable? I think we can keep a variable to define how verbose the traceback should be, something like:
|
Also can you resolve the conflicts? I think is just import merging from 2 branches that's all 🙂 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some changes needed but mostly looks good!
Hey! Implemented the requested changes + fixed the merge conflict |
We could also modify the original error message to something like
to make it more visible such an option exists |
Related to issue #788
This prints out the example inputs and a stacktrace for the error that occurred. I understand that this change would add more excessive error messages that you have tried to avoid
But at least to me this has been the number 1 issue I have been experiencing when testing out dspy for the past week. This change works like a charm in my use case.
If the printed error message seems too excessive with large datasets, then another option would be to add the stacktrace logging behind an env variable that can be set if needed (though my personal preference would be to have the stacktrace visible as the default option and having the possibility to limit the error traces with a similar approach)