From 1146fb2cf9c9bc17c01f9dc1a5c026d5506d655a Mon Sep 17 00:00:00 2001 From: Lei Li Date: Tue, 2 May 2023 13:10:26 -0700 Subject: [PATCH] fix the trial-component loading issue for jobs with mix-case name --- src/smexperiments/_environment.py | 2 +- tests/unit/test_environment.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/smexperiments/_environment.py b/src/smexperiments/_environment.py index 0650a90..fc04b51 100644 --- a/src/smexperiments/_environment.py +++ b/src/smexperiments/_environment.py @@ -78,7 +78,7 @@ def get_trial_component(self, sagemaker_boto_client): while time.time() - start < 300: summaries = list( trial_component.TrialComponent.list( - source_arn=self.source_arn.lower(), sagemaker_boto_client=sagemaker_boto_client + source_arn=self.source_arn, sagemaker_boto_client=sagemaker_boto_client ) ) if summaries: diff --git a/tests/unit/test_environment.py b/tests/unit/test_environment.py index 4c27a12..00a1904 100644 --- a/tests/unit/test_environment.py +++ b/tests/unit/test_environment.py @@ -77,7 +77,7 @@ def test_resolve_trial_component(training_job_env, sagemaker_boto_client): tc = environment.get_trial_component(sagemaker_boto_client) assert trial_component_name == tc.trial_component_name - sagemaker_boto_client.list_trial_components.assert_called_with(SourceArn="arn:1234abcde") + sagemaker_boto_client.list_trial_components.assert_called_with(SourceArn="arn:1234aBcDe") sagemaker_boto_client.describe_trial_component.assert_called_with(TrialComponentName=trial_component_name)