-
Notifications
You must be signed in to change notification settings - Fork 597
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(ImageBuf): auto print uncaught IB errors
Advanced users know to check error returns and retrieve errors. New users often just try OIIO calls with no error checks when they don't get behavior they want, ask questions to the dev team. We hypothesize that if they only saw the text of the error messages that they never retrieved, they could probably self-diagnose many of their problems. This patch makes an ImageBuf, when it is destryed, print any pending error messages that were never retrieved. It happens by default, but can be disabled by setting the new global attribute "imagebuf:print_uncaught_errors" to 0 (it defaults to 1). This doesn't cover everything, but for ImageBuf and ImageBufAlgo, maybe it will help some users? It could annoy advanced users who intend to not retrieve error messages (why?) but still don't want this printed. But that's who the new attribute is for. Signed-off-by: Larry Gritz <[email protected]>
- Loading branch information
Showing
5 changed files
with
47 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters