OasisLMF/ODS_Tools

Oasis Models producing `Deprecated key` warnings after keys are updated

Charlie-Farrar opened this issue · 0 comments

Issue Description

When running the Oasis Models, they give back a Deprecated key in analysis_settings.json warning for the keys model_supplier_id and model_name_id :

Deprecated key in analysis_settings.json, "module_supplier_id" updated to "model_supplier_id"
Deprecated key in analysis_settings.json, "model_version_id" updated to "model_name_id"

Both of these keys have been update in analysis_settings.json, however, this warning persists.

This appears to be originating from:

self.logger.warning(f'Deprecated key in {self.settings_type}.json, "{old_key}" updated to "{new_key}"')
:

and

def __init__(self, schema=None, json_path=None):
self.SCHEMA_FILE = 'analysis_settings_schema.json'
self.compatibility_profile = [
CompatibilityMap(keys='module_supplier_id', updated='model_supplier_id', ver='1.23.0'),
CompatibilityMap(keys='model_version_id', updated='model_name_id', ver='1.23.0'),
]
super(AnalysisSettingSchema, self).__init__(schema, json_path, 'analysis_settings')
:

Steps to Reproduce (Bugs only)

  1. Pull OasisModels repo
  2. Navigate to {any model}/tests/test_x and run oasislmf model run --config oasislmf.json
  3. This will produce the warnings

Version / Environment information

1.28