Permalink
Browse files

refactor(scripts): move import into else branch

  • Loading branch information...
philbooth committed Dec 14, 2018
1 parent 48d9c8f commit a0da41951d1d536f539bf4c457caf6a6990020f7
Showing with 2 additions and 2 deletions.
  1. +1 −1 import_counts.py
  2. +1 −1 import_events.py
@@ -23,11 +23,11 @@ def env_or_default(variable_name, default_value):

return default_value

aws = boto.provider.Provider("aws")
AWS_IAM_ROLE = env_or_default('AWS_IAM_ROLE', None)
if AWS_IAM_ROLE is not None:
CREDENTIALS="aws_iam_role={AWS_IAM_ROLE}".format(AWS_IAM_ROLE=AWS_IAM_ROLE)
else:
aws = boto.provider.Provider("aws")
AWS_ACCESS_KEY = env_or_default("AWS_ACCESS_KEY", aws.get_access_key())
AWS_SECRET_KEY = env_or_default("AWS_SECRET_KEY", aws.get_secret_key())
CREDENTIALS="aws_access_key_id={AWS_ACCESS_KEY};aws_secret_access_key={AWS_SECRET_KEY}".format(
@@ -23,11 +23,11 @@ def env_or_default(variable_name, default_value):

return default_value

aws = boto.provider.Provider("aws")
AWS_IAM_ROLE = env_or_default('AWS_IAM_ROLE', None)
if AWS_IAM_ROLE is not None:
CREDENTIALS="aws_iam_role={AWS_IAM_ROLE}".format(AWS_IAM_ROLE=AWS_IAM_ROLE)
else:
aws = boto.provider.Provider("aws")
AWS_ACCESS_KEY = env_or_default("AWS_ACCESS_KEY", aws.get_access_key())
AWS_SECRET_KEY = env_or_default("AWS_SECRET_KEY", aws.get_secret_key())
CREDENTIALS="aws_access_key_id={AWS_ACCESS_KEY};aws_secret_access_key={AWS_SECRET_KEY}".format(

0 comments on commit a0da419

Please sign in to comment.