| Home | Trees | Indices | Help |
|
|---|
|
|
|
|||
| RecoverableApplyErrorException | ||
| FatalApplyErrorException | ||
|
|||
|
errors_have_recoverable_error() Used to see if there was a recoverable error reported with errors_log_recoverable_exception() or errors_log_recoverable_error(). |
||
|
errors_log_recoverable_error(domain,
msg) Records the presence of a recoverable error to the debug log (see debuglog). |
||
|
errors_have_fatal_error() Used to see if there was a fatal error reported with errors_log_fatal_error(). |
||
|
errors_log_fatal_error(domain,
msg) Records the presence of a fatal error to the debug log (see debuglog). |
||
|
errors_log_recoverable_exception(domain,
msg) Reports the current exception to the debug log (see debuglog), and records the presence of a recoverable error. |
||
|
errors_exit_helper_normally(log_config_filename) Used only from helper programs for Sabayon. |
||
|
errors_exit_with_fatal_exception(domain,
log_config_filename) Exits the program when a fatal exception has occurred. |
||
|
checked_callback(domain) Used as a function decorator. |
||
|
|||
|
_have_recoverable_error = True
|
||
|
_have_fatal_error = True
|
||
|
|||
Used to see if there was a recoverable error reported with errors_log_recoverable_exception() or errors_log_recoverable_error(). Return value: True if errors_log_recoverable_exception() has been called; False otherwise. |
|
Used to see if there was a fatal error reported with errors_log_fatal_error(). Return value: True if errors_log_fatal_error() has been called; False otherwise. |
|
|
|
|
Used as a function decorator. You should prefix *all* your callbacks with this decorator:
@checked_callback ("domain")
def my_callback (...):
...
If an uncaught exception happens in the callback, the decorator will catch the exception,
call errors.errors_log_fatal_error() to flag the presence of a fatal error, and it will
also exit the main loop. In turn, the main loop is expected to have this form:
gtk.main ()
if errors.errors_have_fatal_error ():
print "a fatal error occurred" # or anything else you want to do
|
|
|||
_have_recoverable_errorNone
|
_have_fatal_errorNone
|
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0alpha3 on Sun Jun 16 00:00:27 2013 | http://epydoc.sourceforge.net |