From 3e7aa429fad4bf0508c5781118064222685357c1 Mon Sep 17 00:00:00 2001 From: Emily Doherty Date: Mon, 2 Oct 2023 01:05:51 -0700 Subject: [PATCH] Upgrade current to support both retail and classic, as well as more regions --- wow-token-current.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/wow-token-current.py b/wow-token-current.py index 276b8c8..359eb52 100644 --- a/wow-token-current.py +++ b/wow-token-current.py @@ -8,7 +8,7 @@ dynamo_region_map = { 'us-west-2': 'us-west-2', 'us-east-1': 'us-east-1', 'us-east-2': 'us-east-2', - 'ap-south-1': 'eu-north-1', + 'ap-south-1': 'ap-south-1', 'ap-northeast-3': 'ap-northeast-1', 'ap-northeast-2': 'ap-northeast-1', 'ap-southeast-1': 'ap-southeast-1', @@ -16,9 +16,9 @@ dynamo_region_map = { 'ap-northeast-1': 'ap-northeast-1', 'ca-central-1': 'us-east-1', 'eu-central-1': 'eu-north-1', - 'eu-west-1': 'eu-north-1', - 'eu-west-2': 'eu-north-1', - 'eu-west-3': 'eu-north-1', + 'eu-west-1': 'eu-west-1', + 'eu-west-2': 'eu-west-1', + 'eu-west-3': 'eu-west-3', 'eu-north-1': 'eu-north-1', 'sa-east-1': 'sa-east-1', 'eu-south-1': 'eu-north-1' @@ -27,7 +27,7 @@ local_region = '' if os.environ['AWS_REGION'] in dynamo_region_map: local_region = dynamo_region_map[os.environ['AWS_REGION']] else: - local_region = 'eu-north-1' + local_region = 'eu-central-1' dynamodb_client = boto3.resource('dynamodb', region_name=local_region) retail_table = dynamodb_client.Table('wow-token-price')