Details
-
Type:
Epic
-
Status: To Do
-
Resolution: Unresolved
-
Fix Version/s: None
-
Component/s: None
-
Labels:
-
Epic Name:generic Exceptions
Description
There are a lot of except Exception blocks in our code. These blocks often just swallow the error, either logging a message or just continue-ing without saying anything. In almost every case (I can't prove it's every case without further exploration), we should only catch a very specific and short list of exceptions. The same applies to except lsst.pex.exceptions.Exception and except pexExcept.Exception.
I'm making this an epic as I started filling in the components list and ended up with just about every LSST owned package, so I figure this is best done on a package-by-package basis, or at least on groups of packages.
Filing as critical, as we already know of cases where this bug has hidden other problems (e.g. DM-13803).
Attachments
Issue Links
- relates to
-
DM-9159 Catch-and-ignore should not apply to any exception
- To Do
-
DM-16537 Fix masked exceptions in makeCoaddTempExp
- In Review
-
DM-14290 Do not raise generic Exceptions
- Done
-
DM-13803 Bypass handling catches too many exceptions
- Done
-
DM-35538 Tasks that create Parquet tables should fail on missing/all-NaN columns.
- To Do
While the general principle is correct, I'm not sure we should ban cases like this:
do_something_specific
do_something_in_another_way
where overall failure in the case of an unexpected exception is undesirable.