rotary-genomics / rotary

Assembly/annotation workflow for Nanopore-based microbial genome data containing circular DNA elements
BSD 3-Clause "New" or "Revised" License
2 stars 1 forks source link

Validate config is up to date when running rotary run. #79

Closed LeeBergstrand closed 4 months ago

LeeBergstrand commented 10 months ago

Problem Description

Problem Solution

jmtsuji commented 9 months ago

Sounds like a nice idea. For example, we could write a function that reads all the variable names (and maybe their expected types??) in the template config and then compares those variables to the contents of the user-provided config. The function could throw an error or warning if any variables are missing in the user-provided config. This solution would not know which variables are "key" or not, though...

LeeBergstrand commented 9 months ago

As discussed above we should add some config validation related to: https://github.com/jmtsuji/rotary/pull/75#discussion_r1391317427

LeeBergstrand commented 4 months ago

Addressed by https://github.com/rotary-genomics/rotary/commit/a03ddae8f54b7184abdde34573ac9736726b5171 and https://github.com/rotary-genomics/pungi/commit/34654fccb6278a753a2d650b8a666a83432cc760

The config is compared to the default config (provided as a path), and the code checks if the keys are missing from the config that are present in the default config.

jmtsuji commented 4 months ago

Great!