Skip to content

Commit 5df7840

Browse files
author
Dan Choi
committed
Fix parameter name for wait
1 parent 2a04096 commit 5df7840

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/sagemaker/tuner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ def start_new(cls, tuner, inputs):
393393
return cls(tuner.sagemaker_session, tuner._current_job_name)
394394

395395
def stop(self):
396-
self.sagemaker_session.stop_tuning_job(HyperParameterTuningJobName=self.name)
396+
self.sagemaker_session.stop_tuning_job(name=self.name)
397397

398398
def wait(self):
399399
self.sagemaker_session.wait_for_tuning_job(self.name)

tests/unit/test_tuner.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ def test_stop_tuning_job(sagemaker_session, tuner):
331331

332332
tuner.stop_tuning_job()
333333

334-
sagemaker_session.stop_tuning_job.assert_called_once_with(HyperParameterTuningJobName=JOB_NAME)
334+
sagemaker_session.stop_tuning_job.assert_called_once_with(name=JOB_NAME)
335335

336336

337337
def test_stop_tuning_job_no_tuning_job(tuner):
@@ -536,7 +536,7 @@ def test_stop(sagemaker_session):
536536
tuning_job = _TuningJob(sagemaker_session, JOB_NAME)
537537
tuning_job.stop()
538538

539-
sagemaker_session.stop_tuning_job.assert_called_once_with(HyperParameterTuningJobName=JOB_NAME)
539+
sagemaker_session.stop_tuning_job.assert_called_once_with(name=JOB_NAME)
540540

541541

542542
def test_tuning_job_wait(sagemaker_session):

0 commit comments

Comments
 (0)