Skip to content

Commit 239d084

Browse files
author
Eli Davidson
committed
add doc string to get_latest_version
1 parent 51cc864 commit 239d084

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6502,7 +6502,7 @@
65026502

65036503
### Documentation changes
65046504

6505-
* add mandatory sagemaker_role argument to Local mode example.
6505+
* add mandatory sagemaker_role argument to Local mode example.
65066506

65076507
## v1.18.6 (2019-03-20)
65086508

src/sagemaker/jumpstart/utils.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1633,6 +1633,8 @@ def get_draft_model_content_bucket(provider: Dict, region: str) -> str:
16331633

16341634

16351635
def get_latest_version(versions: List[str]) -> Optional[str]:
1636+
"""Returns the latest version using sem-ver.
1637+
falls-back to string ordering when not using sem-ver."""
16361638
try:
16371639
return None if not versions else max(versions, key=Version)
16381640
except InvalidVersion:

0 commit comments

Comments
 (0)