diff --git a/include/realizations/catchment/Bmi_Formulation.hpp b/include/realizations/catchment/Bmi_Formulation.hpp index c864535a00..13ad0b426d 100644 --- a/include/realizations/catchment/Bmi_Formulation.hpp +++ b/include/realizations/catchment/Bmi_Formulation.hpp @@ -14,9 +14,9 @@ #define BMI_REALIZATION_CFG_PARAM_REQ__INIT_CONFIG "init_config" #define BMI_REALIZATION_CFG_PARAM_REQ__MAIN_OUT_VAR "main_output_variable" #define BMI_REALIZATION_CFG_PARAM_REQ__MODEL_TYPE "model_type_name" -#define BMI_REALIZATION_CFG_PARAM_REQ__USES_FORCINGS "uses_forcing_file" // Then the optional +#define BMI_REALIZATION_CFG_PARAM_OPT__USES_FORCINGS "uses_forcing_file" #define BMI_REALIZATION_CFG_PARAM_OPT__FORCING_FILE "forcing_file" #define BMI_REALIZATION_CFG_PARAM_OPT__VAR_STD_NAMES "variables_names_map" // TODO: change this (and output_header_fields) to something like output_file_variables to distinguish from BMI output variables diff --git a/include/realizations/catchment/Bmi_Module_Formulation.hpp b/include/realizations/catchment/Bmi_Module_Formulation.hpp index d939e27734..286baf1aeb 100644 --- a/include/realizations/catchment/Bmi_Module_Formulation.hpp +++ b/include/realizations/catchment/Bmi_Module_Formulation.hpp @@ -440,7 +440,7 @@ namespace realization { bool model_initialized = false; std::vector OPTIONAL_PARAMETERS = { - BMI_REALIZATION_CFG_PARAM_REQ__USES_FORCINGS + BMI_REALIZATION_CFG_PARAM_OPT__USES_FORCINGS BMI_REALIZATION_CFG_PARAM_OPT__FORCING_FILE, BMI_REALIZATION_CFG_PARAM_OPT__VAR_STD_NAMES, BMI_REALIZATION_CFG_PARAM_OPT__OUT_VARS, diff --git a/src/realizations/catchment/Bmi_Formulation.cpp b/src/realizations/catchment/Bmi_Formulation.cpp index 008add30a1..2048a47a79 100644 --- a/src/realizations/catchment/Bmi_Formulation.cpp +++ b/src/realizations/catchment/Bmi_Formulation.cpp @@ -3,6 +3,7 @@ namespace realization { const std::vector Bmi_Formulation::OPTIONAL_PARAMETERS = { + BMI_REALIZATION_CFG_PARAM_OPT__USES_FORCINGS BMI_REALIZATION_CFG_PARAM_OPT__FORCING_FILE, BMI_REALIZATION_CFG_PARAM_OPT__VAR_STD_NAMES, BMI_REALIZATION_CFG_PARAM_OPT__OUT_VARS, @@ -15,6 +16,5 @@ namespace realization BMI_REALIZATION_CFG_PARAM_REQ__INIT_CONFIG, BMI_REALIZATION_CFG_PARAM_REQ__MAIN_OUT_VAR, BMI_REALIZATION_CFG_PARAM_REQ__MODEL_TYPE, - BMI_REALIZATION_CFG_PARAM_REQ__USES_FORCINGS }; } diff --git a/src/realizations/catchment/Bmi_Module_Formulation.cpp b/src/realizations/catchment/Bmi_Module_Formulation.cpp index ac52f8f4db..5c6c2c2623 100644 --- a/src/realizations/catchment/Bmi_Module_Formulation.cpp +++ b/src/realizations/catchment/Bmi_Module_Formulation.cpp @@ -304,9 +304,9 @@ namespace realization { // Then optional ... - auto uses_forcings_it = properties.find(BMI_REALIZATION_CFG_PARAM_REQ__USES_FORCINGS); + auto uses_forcings_it = properties.find(BMI_REALIZATION_CFG_PARAM_OPT__USES_FORCINGS); if (uses_forcings_it != properties.end() && uses_forcings_it->second.as_boolean()) { - throw std::runtime_error("The '" BMI_REALIZATION_CFG_PARAM_REQ__USES_FORCINGS "' parameter was removed and cannot be set"); + throw std::runtime_error("The '" BMI_REALIZATION_CFG_PARAM_OPT__USES_FORCINGS "' parameter was removed and cannot be set"); } auto forcing_file_it = properties.find(BMI_REALIZATION_CFG_PARAM_OPT__FORCING_FILE);