Skip to content

Commit 3cbc111

Browse files
DevakiBolleneniDevakiBolleneni
andauthored
Fix PyTorch 2.8 SageMaker Package Regressions (#5520)
* run tests * rebuild and run tests * update sagemaker pin and rebuild image * rebuild image with sm sdk * pin versions and rebuild image * Fix version pins and rebuild image * pins s3fs to prevent the downgrade and rebuild * resolve incompatibilty issue * retry tests * install newer version of s3fs * revert config file * revert version pin changes and pin sm version * build image * put back awscli and boto3 pins * Empty commit to trigger rebuild * fix typo & rerun * fix SM version pin & rerun * add sniffio explicitly & rerun * revert toml file --------- Co-authored-by: DevakiBolleneni <devakib@amazon.com>
1 parent b9a52b8 commit 3cbc111

File tree

2 files changed

+11
-7
lines changed

2 files changed

+11
-7
lines changed

pytorch/training/docker/2.8/py3/Dockerfile.cpu

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ RUN pip install --no-cache-dir \
188188
"requests>=2.32.0" \
189189
"setuptools>=70.0.0" \
190190
"urllib3>=2.5.0" \
191-
"awscli" \
191+
awscli \
192192
opencv-python==4.11.0.86 \
193193
mpi4py \
194194
jinja2>=3.1.6 \
@@ -282,10 +282,12 @@ WORKDIR /
282282
# Install SM packages
283283
RUN pip install --no-cache-dir -U \
284284
smclarify \
285-
"sagemaker>=2" \
285+
"sagemaker==2.254.1" \
286286
sagemaker-experiments \
287287
sagemaker-pytorch-training \
288-
sagemaker-training
288+
sagemaker-training \
289+
# Add sniffio explicitly as it's not included in sagemaker==2.254.1 dependencies
290+
sniffio
289291

290292
# Install extra packages
291293
RUN pip install --no-cache-dir -U \
@@ -297,7 +299,7 @@ RUN pip install --no-cache-dir -U \
297299
scikit-learn \
298300
seaborn \
299301
shap \
300-
cloudpickle
302+
cloudpickle
301303

302304
# Copy workaround script for incorrect hostname
303305
COPY changehostname.c /

pytorch/training/docker/2.8/py3/cu129/Dockerfile.gpu

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -250,10 +250,12 @@ RUN pip install --no-cache-dir -U \
250250
"awscli<1.42.50" \
251251
"boto3<1.40.50" \
252252
smclarify \
253-
"sagemaker>=2" \
253+
"sagemaker==2.254.1" \
254254
sagemaker-experiments \
255255
sagemaker-pytorch-training \
256-
sagemaker-training
256+
sagemaker-training \
257+
# Add sniffio explicitly as it's not included in sagemaker==2.254.1 dependencies
258+
sniffio
257259

258260
# Install extra packages
259261
RUN pip install --no-cache-dir -U \
@@ -265,7 +267,7 @@ RUN pip install --no-cache-dir -U \
265267
shap \
266268
scikit-learn \
267269
seaborn \
268-
cloudpickle
270+
cloudpickle
269271

270272
COPY setup_oss_compliance.sh setup_oss_compliance.sh
271273
RUN bash setup_oss_compliance.sh ${PYTHON} && rm setup_oss_compliance.sh

0 commit comments

Comments
 (0)