Skip to content

Commit

Permalink
Fixed bug that prevented adding new presets
Browse files Browse the repository at this point in the history
  • Loading branch information
tmacdonald1973 committed Oct 18, 2021
1 parent d3573da commit 548854f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
4 changes: 4 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
Changelog for SumoToolBox

10-18-2021 0.11.1

* [General] Fixed bugs preventing the addition of new presets.

10-11-2021 0.11.0

* [Content] Fixed a bug that made it impossible to copy from Admin and Global folders.
Expand Down
15 changes: 11 additions & 4 deletions sumotoolbox.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
__author__ = 'Tim MacDonald'
__version__ = '0.11'
__version__ = '0.11.1'
# Copyright 2015 Timothy MacDonald
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
Expand Down Expand Up @@ -826,9 +826,16 @@ def create_preset_non_interactive(self, preset_name, sumo_region, accesskeyid, a
'prod': 'US1',
'us2': 'US2',
'fed': 'FED',
'mon': 'CA'}
if sumo_region in deployment_conversion:
deployment = deployment_conversion[sumo_region]
'mon': 'CA',
'de': 'DE',
'eu': 'EU',
'in': 'IN',
'jp': 'JP',
'au': 'AU',
'us1': 'US1',
'ca': 'CA'}
if str(sumo_region).lower() in deployment_conversion:
deployment = deployment_conversion[str(sumo_region).lower()]
else:
logger.info(f'Unknown deployment: {sumo_region}')
return 'ERROR'
Expand Down

0 comments on commit 548854f

Please sign in to comment.