-
Notifications
You must be signed in to change notification settings - Fork 2
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
No warning/ no error despite missing CO2 data #62
Comments
Okay, makes sense.
I'm not sure if this should be a fail case. If no scenario in the experimental design is provided, but a multiplier is enabled, then rSFSW2 will grab the scenario from whatever is being run: I could remove this functionality if you think it's too dangerous, per say. With this approach the carbon values have the potential to not exist for the scenario. Should it fail here? Or just be a warning? |
If we request a specific simulation setup, but inputs are not available, then the run has to fail. |
So to be clear, if someone enabled CO2, but didn't specify the scenario because they wanted it to be extracted with the above code, and the extracted scenario has no CO2 data, it should fail. Correct? |
The code cited in three comments above
|
Four checks have been added: A duplicated year was entered in the scenario data. Run cancels even if that year was not being run, simply because invalid input data should not be acceptable. Carbon.in was empty. Should never happen, but it will fail when it does. The scenario was not found. A requested year was missing ppm data. This only fails if that year was being used, because it is valid to have skips in the input data (e.g. only have data for 1800-1900 and 2000-2100). |
As long as there is an appropriately named
carbon.in
file (name as infiles.in
), the execution runs without errors and without warnings -- whether or not thecarbon.in
file is--> example output from
co2_effects.yr
:--> example output for
carbon.in
with data for years 2010 and 2012:--> example output for
carbon.in
with multiple values data for year 2010: only last value usedI don't think it makes sense to run a simulation with missing data. I suggest to have the code error out if there are missing years and/or multiple years for a scenario.
The text was updated successfully, but these errors were encountered: