ACCESS-NRI / um2nc-standalone

Standalone um2nc/um2netcdf to unify development efforts in a single repository.
Apache License 2.0
0 stars 0 forks source link

Refactoring: split process() into subcomponents #14

Open truth-quark opened 5 months ago

truth-quark commented 5 months ago

Background: the process() workflow function is ~140 SLOC, covering multiple processing steps. Testing as a whole is too difficult, given the volume of logic and integration. Work on the func should generally include:

  1. Split into sub functions to facilitate unit testing
  2. Retrofit unit tests
  3. Refactor/clean processing logic for simplification
  4. Reorder code blocks to group like functionality
  5. Refactor to separate cube manipulation & cube I/O steps (e.g. split into filtering, cube modification, writing cubes)

This helps with modularity, readability, workflow modification & future expansion.

Tasks:

truth-quark commented 4 months ago

Adding link to related ESM 1.5 project issue: https://github.com/ACCESS-NRI/access-esm1.5-configs/issues/3

truth-quark commented 4 months ago

@blimlim & @jo-basevi I've updated this high level issue to better explain the work behind process().

Does it make sense & is anything missing?