Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove error if config_dict value does not have default type #3206

Merged
merged 3 commits into from
Jul 18, 2024

Conversation

nefrathenrici
Copy link
Member

@nefrathenrici nefrathenrici commented Jul 18, 2024

This loosens the type restrictions for the YAML files - we can finally have hyperdiff: false!

If the AtmosConfig constructor is unable to convert an input value to the default type, just warn the user and use the given input value:

┌ Warning: Failed to convert `config_dict["hyperdiff"] = false` to default type String, keeping original value

This PR also follows up on #3203, fixing unused YAML keys and adding an exception for the diagnostics key, since it is not found in the default config file.

Example of undesired behavior:

┌ Warning: The configuration passed to ClimaAtmos contains unused keys: diagnostics
└ @ ClimaAtmos /central/scratch/esm/slurm-buildkite/climaatmos-ci/19847/climaatmos-ci/src/solver/yaml_helper.jl:88

@nefrathenrici nefrathenrici added this pull request to the merge queue Jul 18, 2024
Merged via the queue into main with commit 73a52d0 Jul 18, 2024
13 of 14 checks passed
@nefrathenrici nefrathenrici deleted the ne/hotfix branch July 18, 2024 22:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants