Skip to content

Harmonize missing inlist/section in inlist handling #957

@VincentVanlaer

Description

@VincentVanlaer

I was looking a bit deeper into the issues @mathren highlighted in #954 where missing a missing pgbinary inlist causes somewhat of messy exit. While the fix is not too hard (it even simplifies the code), I did notice that the same code is repeated in various parts of the code base, but with slight differences.

  • kap, eos, and colors allow the first inlist file in a chain to be missing. Missing kap and eos namelist sections lead to a warning, but no hard error.
  • binary_job, binary_controls, astero_search_controls, astero_pgstar_controls, controls, pgstar, and pgbinary produce a hard error whenever the can't read a file or don't find their namelist sections (assuming the module is enabled).

I can see benefits for both cases: early warning to the user if they made a mistake vs. less unneeded noise.

Do we want to keep the current behaviour or pick one of the options? The difference for refactoring the code is limited.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions