Skip to content

Commit 2be47df

Browse files
authored
chore: remove sys.path override (#2380)
Co-authored-by: Jacob Fuss <[email protected]>
1 parent 9306a03 commit 2be47df

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

bin/sam-translate.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
from samtranslator.translator.transform import transform
3838
from samtranslator.yaml_helper import yaml_parse
3939
from samtranslator.model.exceptions import InvalidDocumentException
40-
from samtranslator.feature_toggle.feature_toggle import FeatureToggleLocalConfigProvider, FeatureToggle
4140

4241
LOG = logging.getLogger(__name__)
4342
cli_options = docopt(__doc__)
@@ -98,15 +97,7 @@ def transform_template(input_file_path, output_file_path):
9897
sam_template = yaml_parse(f)
9998

10099
try:
101-
feature_toggle = FeatureToggle(
102-
FeatureToggleLocalConfigProvider(
103-
os.path.join(my_path, "..", "tests", "feature_toggle", "input", "feature_toggle_config.json")
104-
),
105-
stage=None,
106-
account_id=None,
107-
region=None,
108-
)
109-
cloud_formation_template = transform(sam_template, {}, ManagedPolicyLoader(iam_client), feature_toggle)
100+
cloud_formation_template = transform(sam_template, {}, ManagedPolicyLoader(iam_client))
110101
cloud_formation_template_prettified = json.dumps(cloud_formation_template, indent=1)
111102

112103
with open(output_file_path, "w") as f:

samtranslator/feature_toggle/feature_toggle.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@
1313
)
1414
from samtranslator.metrics.method_decorator import cw_timer
1515

16-
my_path = os.path.dirname(os.path.abspath(__file__))
17-
sys.path.insert(0, my_path + "/..")
18-
1916
LOG = logging.getLogger(__name__)
2017

2118

0 commit comments

Comments
 (0)