Skip to content

Commit

Permalink
(v3.2.9) Environment registration field bug (#402)
Browse files Browse the repository at this point in the history
* Solved variable_names field bug in parsing function

* Updated Sinergym version from 3.2.8 to 3.2.9
  • Loading branch information
AlejandroCN7 authored Mar 26, 2024
1 parent b4052e2 commit d7b20e1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions sinergym/utils/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,16 +293,16 @@ def json_to_variables(variables: Dict[str, Any]) -> Dict[str, Tuple[str, str]]:
else:
raise RuntimeError

elif isinstance(specification['variables_names'], list):
elif isinstance(specification['variable_names'], list):

if isinstance(specification['keys'], str):
raise RuntimeError

elif isinstance(specification['keys'], list):
assert len( specification['variables_names']) == len(
assert len( specification['variable_names']) == len(
specification['keys']), 'variable names and keys must have the same len in {}'.format(variable)
for variable_name, key_name in list(
zip(specification['variables_names'], specification['keys'])):
zip(specification['variable_names'], specification['keys'])):
output[variable_name] = (variable, key_name)

else:
Expand Down
2 changes: 1 addition & 1 deletion sinergym/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.2.8
3.2.9

0 comments on commit d7b20e1

Please sign in to comment.