geoschem / Cloud-J

Cloud-J is multi-scattering eight-stream radiative transfer model for solar radiation based on Fast-J. It was originally developed by Michael J. Prather.
GNU General Public License v3.0
3 stars 6 forks source link

Improve error handling #19

Closed lizziel closed 3 days ago

lizziel commented 2 weeks ago

Name and Institution (Required)

Name: Lizzie Lundgren Institution: Harvard University

Describe the update

This PR removes the legacy EXITC subroutine which stops the model upon error and replaces it with new subroutine CLOUDJ_ERROR which prints a message and returns RC flag equal to CLDJ_FAILURE. The RC flag is then passed up the calling stack to the parent model for model-specific error handling.

This PR also includes a few no diff structural improvements, including removing redundant instances of implicit none and using "(:)" when assigning all values of an array a constant value.

This update requires updates in all parent models, including GEOS-Chem.

Expected changes

This is a no diff update.

Reference(s)

None

Related Github Issues and PRs

https://github.com/geoschem/geos-chem/pull/2353 (Merge required at the time as this PR)

yantosca commented 3 days ago

Thanks @lizziel!