Project

Profile

Help

Task #2760

Updated by bmbouter over 7 years ago

The "Contributing Guide":http://docs.pulpproject.org/en/3.0/nightly/contributing/index.html plugin API part of the docs needs a new top-level general section added to it called "Error Handling". Inside of that page a section on "Errors in Tasks" should also be added about how errors are handled while running a task. The basic very simple things to get across are that: 

 * Uncaught uncaught exceptions are treated as fatal exceptions, the task is marked as failed, and the error representation is returned to the user as the task 'error'. 
 * General Python Coded exceptions should be used whenever possible. for known error situations. 
 * Coded general Python exceptions should be used for known error situations. These should link to "<code>PulpException</code>":http://docs.pulpproject.org/en/3.0/nightly/contributing/platform_api/exceptions.html#pulp.exceptions.base.PulpException whenever possible 
 * Non non fatal exceptions can be recorded with the <code>append_non_fatal_error()</code> and it should link them to "that that part of the plugin API docs":http://docs.pulpproject.org/en/3.0/nightly/contributing/plugin_api/index.html#pulp.plugin.tasking.Task 
 * These non-fatal exceptions will be returned with the task details through the API. docs:    http://docs.pulpproject.org/en/3.0/nightly/contributing/plugin_api/index.html#pulp.plugin.tasking.Task

Back