MolSSI / QCFractal

A distributed compute and database platform for quantum chemistry.
https://molssi.github.io/QCFractal/
BSD 3-Clause "New" or "Revised" License
144 stars 47 forks source link

[WIP] Improve handling of errored calculation #658

Closed bennybp closed 3 years ago

bennybp commented 3 years ago

Description

This PR aims to improve the storage of errors that get returned by managers.

  1. Removes responsibility of modifying base_result in queue_mark_complete and queue_mark_error. This is best handled in the procedures, and reduces the number of database queries required
  2. The procedure parsers (handle_completed_output) are now responsible for adding manager_name and modified_on to the result/procedure they are already modifying
  3. Removes calls to queue_mark_error from queue handler
  4. Creates a semi-dummy procedure class to handle errors. This gets called like any other procedure parser, keeping the handling consistent.

The class mentioned in (4) will properly copy as much data as it can from the FailedOperation that is returned by the managers. Right now, only the error member of that class is copied, stripping it of useful info (including some outputs)

That class can be expanded in many ways, including automatic restarting of calculations.

Changelog description

Status

lgtm-com[bot] commented 3 years ago

This pull request introduces 7 alerts when merging ad58ab477816a0403af365a626df2a9e489dbe4d into 78e4b18082db0ec03677b335d03a80a5f4b90240 - view on LGTM.com

new alerts:

lgtm-com[bot] commented 3 years ago

This pull request introduces 8 alerts when merging 89c71c8e2e5f289b514b3ce6ab73f701c71792f8 into 78e4b18082db0ec03677b335d03a80a5f4b90240 - view on LGTM.com

new alerts:

codecov[bot] commented 3 years ago

Codecov Report

Merging #658 (78e4b18) into master (78e4b18) will not change coverage. The diff coverage is n/a.

lgtm-com[bot] commented 3 years ago

This pull request introduces 8 alerts when merging bfe41e232b82bcfce8985e174edc31ca90efd09d into 78e4b18082db0ec03677b335d03a80a5f4b90240 - view on LGTM.com

new alerts: