sagemaker-core 1.0.15__py3-none-any.whl → 1.0.17__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of sagemaker-core might be problematic. Click here for more details.
- sagemaker_core/main/code_injection/codec.py +16 -2
- sagemaker_core/main/code_injection/shape_dag.py +733 -2
- sagemaker_core/main/config_schema.py +4 -0
- sagemaker_core/main/resources.py +10609 -8657
- sagemaker_core/main/shapes.py +434 -4
- sagemaker_core/tools/method.py +3 -2
- sagemaker_core/tools/resources_codegen.py +7 -2
- sagemaker_core/tools/shapes_extractor.py +12 -7
- {sagemaker_core-1.0.15.dist-info → sagemaker_core-1.0.17.dist-info}/METADATA +13 -13
- {sagemaker_core-1.0.15.dist-info → sagemaker_core-1.0.17.dist-info}/RECORD +13 -13
- {sagemaker_core-1.0.15.dist-info → sagemaker_core-1.0.17.dist-info}/WHEEL +1 -1
- {sagemaker_core-1.0.15.dist-info → sagemaker_core-1.0.17.dist-info}/LICENSE +0 -0
- {sagemaker_core-1.0.15.dist-info → sagemaker_core-1.0.17.dist-info}/top_level.txt +0 -0
|
@@ -931,7 +931,9 @@ class ResourcesCodeGen:
|
|
|
931
931
|
for e in errors:
|
|
932
932
|
error_shape = e["shape"]
|
|
933
933
|
error_shape_dict = self.shapes[error_shape]
|
|
934
|
-
error_shape_documentation = error_shape_dict.get("documentation")
|
|
934
|
+
error_shape_documentation = error_shape_dict.get("documentation")
|
|
935
|
+
if error_shape_documentation:
|
|
936
|
+
error_shape_documentation.strip()
|
|
935
937
|
shape_errors_and_docstrings[error_shape] = error_shape_documentation
|
|
936
938
|
sorted_keys = sorted(shape_errors_and_docstrings.keys())
|
|
937
939
|
return {key: shape_errors_and_docstrings[key] for key in sorted_keys}
|
|
@@ -939,7 +941,10 @@ class ResourcesCodeGen:
|
|
|
939
941
|
def _exception_docstring(self, operation: str) -> str:
|
|
940
942
|
_docstring = RESOURCE_METHOD_EXCEPTION_DOCSTRING
|
|
941
943
|
for error, documentaion in self._fetch_shape_errors_and_doc_strings(operation).items():
|
|
942
|
-
|
|
944
|
+
if documentaion:
|
|
945
|
+
_docstring += f"\n {error}: {remove_html_tags(documentaion).strip()}"
|
|
946
|
+
else:
|
|
947
|
+
_docstring += f"\n {error}"
|
|
943
948
|
return _docstring
|
|
944
949
|
|
|
945
950
|
def _generate_docstring(
|
|
@@ -119,19 +119,24 @@ class ShapesExtractor:
|
|
|
119
119
|
|
|
120
120
|
def _evaluate_list_type(self, member_shape):
|
|
121
121
|
list_shape_name = member_shape["member"]["shape"]
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
122
|
+
list_shape_member = self.combined_shapes[list_shape_name]
|
|
123
|
+
list_shape_type = list_shape_member["type"]
|
|
124
|
+
if list_shape_type == "list":
|
|
125
|
+
member_type = f"List[{self._evaluate_list_type(list_shape_member)}]"
|
|
126
|
+
elif list_shape_type == "map":
|
|
127
|
+
member_type = f"List[{self._evaluate_map_type(list_shape_member)}]"
|
|
128
|
+
elif list_shape_type == "structure":
|
|
128
129
|
# handling an edge case of nested structure
|
|
129
130
|
if list_shape_name == "SearchExpression":
|
|
130
131
|
member_type = f"List['{list_shape_name}']"
|
|
131
132
|
else:
|
|
132
133
|
member_type = f"List[{list_shape_name}]"
|
|
133
|
-
|
|
134
|
+
elif list_shape_type in BASIC_JSON_TYPES_TO_PYTHON_TYPES.keys():
|
|
134
135
|
member_type = f"List[{BASIC_JSON_TYPES_TO_PYTHON_TYPES[list_shape_type]}]"
|
|
136
|
+
else:
|
|
137
|
+
raise Exception(
|
|
138
|
+
f"Unhandled list shape key type {list_shape_type} for Shape: {list_shape_name} encountered, needs extra logic to handle this"
|
|
139
|
+
)
|
|
135
140
|
return member_type
|
|
136
141
|
|
|
137
142
|
def _evaluate_map_type(self, member_shape):
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: sagemaker-core
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.17
|
|
4
4
|
Summary: An python package for sagemaker core functionalities
|
|
5
5
|
Author-email: AWS <sagemaker-interests@amazon.com>
|
|
6
6
|
Project-URL: Repository, https://github.com/aws/sagemaker-core.git
|
|
@@ -15,19 +15,19 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
15
15
|
Requires-Python: >=3.8
|
|
16
16
|
Description-Content-Type: text/x-rst
|
|
17
17
|
License-File: LICENSE
|
|
18
|
-
Requires-Dist: boto3
|
|
19
|
-
Requires-Dist: pydantic
|
|
20
|
-
Requires-Dist: PyYAML
|
|
21
|
-
Requires-Dist: jsonschema
|
|
22
|
-
Requires-Dist: platformdirs
|
|
23
|
-
Requires-Dist: rich
|
|
24
|
-
Requires-Dist: mock
|
|
25
|
-
Requires-Dist: importlib-metadata
|
|
18
|
+
Requires-Dist: boto3<2.0.0,>=1.35.75
|
|
19
|
+
Requires-Dist: pydantic<3.0.0,>=2.0.0
|
|
20
|
+
Requires-Dist: PyYAML<7.0,>=6.0
|
|
21
|
+
Requires-Dist: jsonschema<5.0.0
|
|
22
|
+
Requires-Dist: platformdirs<5.0.0,>=4.0.0
|
|
23
|
+
Requires-Dist: rich<14.0.0,>=13.0.0
|
|
24
|
+
Requires-Dist: mock<5.0,>4.0
|
|
25
|
+
Requires-Dist: importlib-metadata<7.0,>=1.4.0
|
|
26
26
|
Provides-Extra: codegen
|
|
27
|
-
Requires-Dist: black
|
|
28
|
-
Requires-Dist: pandas
|
|
29
|
-
Requires-Dist: pytest
|
|
30
|
-
Requires-Dist: pylint
|
|
27
|
+
Requires-Dist: black<25.0.0,>=24.3.0; extra == "codegen"
|
|
28
|
+
Requires-Dist: pandas<3.0.0,>=2.0.0; extra == "codegen"
|
|
29
|
+
Requires-Dist: pytest<9.0.0,>=8.0.0; extra == "codegen"
|
|
30
|
+
Requires-Dist: pylint<4.0.0,>=3.0.0; extra == "codegen"
|
|
31
31
|
|
|
32
32
|
.. image:: https://github.com/aws/sagemaker-python-sdk/raw/master/branding/icon/sagemaker-banner.png
|
|
33
33
|
:height: 100px
|
|
@@ -3,33 +3,33 @@ sagemaker_core/_version.py,sha256=t-XEKT8_pvKkl5z_UrfcIU256c_NxaI16qGWMuNVpbM,32
|
|
|
3
3
|
sagemaker_core/helper/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
4
|
sagemaker_core/helper/session_helper.py,sha256=GO1UJgpN1L9a25nYlVb-KWk4KvmFzVkLqFMqw-VaI4c,33126
|
|
5
5
|
sagemaker_core/main/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
6
|
-
sagemaker_core/main/config_schema.py,sha256=
|
|
6
|
+
sagemaker_core/main/config_schema.py,sha256=kfQvf_japrsitTwXTdUaYhOPqKTBBwIE_-ebNeWD-yY,57229
|
|
7
7
|
sagemaker_core/main/exceptions.py,sha256=87DUlrmHxaWoiYNlpNY9ixxFMPRk_dIGPsA2e_xdVwQ,5602
|
|
8
8
|
sagemaker_core/main/intelligent_defaults_helper.py,sha256=5SDM6UavZtp-k5LhqRL7GRIDgzFB5UsC_p7YuiSPK9A,8334
|
|
9
9
|
sagemaker_core/main/logs.py,sha256=yfEH7uP91nbE1lefymOlBr81ziBzsDSIOF2Qyd54FJE,6241
|
|
10
|
-
sagemaker_core/main/resources.py,sha256=
|
|
11
|
-
sagemaker_core/main/shapes.py,sha256=
|
|
10
|
+
sagemaker_core/main/resources.py,sha256=9SXDc6rvZKgO3E7Sx00YFaE9GSprLM8-7OPZI59R0wE,1404781
|
|
11
|
+
sagemaker_core/main/shapes.py,sha256=BFyvKO-l6BVhlAr683fY_73s4Ed6oX7WOiiPVWKsiKs,722024
|
|
12
12
|
sagemaker_core/main/user_agent.py,sha256=4sZybDXkzRoZnOnVDQ8p8zFTfiRJdsH7amDWInVQ4xU,2708
|
|
13
13
|
sagemaker_core/main/utils.py,sha256=LCFDM6oxf6_e1i-_Dgtkm3ehl7YfoEpJ2kTTFTL6iOU,18471
|
|
14
14
|
sagemaker_core/main/code_injection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
15
15
|
sagemaker_core/main/code_injection/base.py,sha256=11_Jif0nOzfbLGlXaacKf-wcizzfS64U0OSZGoVffFU,1733
|
|
16
|
-
sagemaker_core/main/code_injection/codec.py,sha256=
|
|
16
|
+
sagemaker_core/main/code_injection/codec.py,sha256=nA51E9iNWHyKou1G23rKSRL4WitdkFRbMuFkyrGHzKU,8428
|
|
17
17
|
sagemaker_core/main/code_injection/constants.py,sha256=2ICExGge8vAWx7lSTW0JGh-bH1korkvpOpDu5M63eI4,980
|
|
18
|
-
sagemaker_core/main/code_injection/shape_dag.py,sha256=
|
|
18
|
+
sagemaker_core/main/code_injection/shape_dag.py,sha256=8NmYwxcnkAjiTK1oeOrmNMkhs9ZqBwWbxBCFs29ooxY,693934
|
|
19
19
|
sagemaker_core/resources/__init__.py,sha256=EAYTFMN-nPjnPjjBbhIUeaL67FLKNPd7qbcbl9VIrws,31
|
|
20
20
|
sagemaker_core/shapes/__init__.py,sha256=RnbIu9eTxKt-DNsOFJabrWIgrrtS9_SdAozP9JBl_ic,28
|
|
21
21
|
sagemaker_core/tools/__init__.py,sha256=xX79JImxCVzrWMnjgntLCve2G5I-R4pRar5s20kT9Rs,56
|
|
22
22
|
sagemaker_core/tools/codegen.py,sha256=mKWVi2pWnPxyIoWUEPYjEc9Gw7D9bCOrHqa00yzIZ1o,2005
|
|
23
23
|
sagemaker_core/tools/constants.py,sha256=a2WjUDK7gzxgilZs99vp30qh4kQ-y6JKhrwwqVAA12o,3385
|
|
24
24
|
sagemaker_core/tools/data_extractor.py,sha256=pNfmTA0NUA96IgfLrla7a36Qjc1NljbwgZYaOhouKqQ,2113
|
|
25
|
-
sagemaker_core/tools/method.py,sha256=
|
|
26
|
-
sagemaker_core/tools/resources_codegen.py,sha256=
|
|
25
|
+
sagemaker_core/tools/method.py,sha256=Ud2YeH2SPkj7xtIxBuUdRfQwCmovMUzGGkcIvzhpQeQ,805
|
|
26
|
+
sagemaker_core/tools/resources_codegen.py,sha256=bnufJgmVUcIGyMifZKbtwaO_bG_0bN2_A7CYq629pNc,84550
|
|
27
27
|
sagemaker_core/tools/resources_extractor.py,sha256=hN61ehZbPnhFW-2FIVDi7NsEz4rLvGr-WoglHQGfrug,14523
|
|
28
28
|
sagemaker_core/tools/shapes_codegen.py,sha256=_ve959bwH8usZ6dPlpXxi2on9t0hLpcmhRWnaWHCWMQ,11745
|
|
29
|
-
sagemaker_core/tools/shapes_extractor.py,sha256=
|
|
29
|
+
sagemaker_core/tools/shapes_extractor.py,sha256=GFy55JHGW0V8cwN5SL5gGLUxihLGswueyh5iNCn1sYk,12310
|
|
30
30
|
sagemaker_core/tools/templates.py,sha256=yX2RQKeClgYwKS5Qu_mDpnWJIBCuj0yELrdm95aiTpk,23262
|
|
31
|
-
sagemaker_core-1.0.
|
|
32
|
-
sagemaker_core-1.0.
|
|
33
|
-
sagemaker_core-1.0.
|
|
34
|
-
sagemaker_core-1.0.
|
|
35
|
-
sagemaker_core-1.0.
|
|
31
|
+
sagemaker_core-1.0.17.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
32
|
+
sagemaker_core-1.0.17.dist-info/METADATA,sha256=7ZbFj4VOtErNDYpF24UPtnMZ2cO1Gd768ZvoD0EJ0Sc,4863
|
|
33
|
+
sagemaker_core-1.0.17.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
|
34
|
+
sagemaker_core-1.0.17.dist-info/top_level.txt,sha256=R3GAZZ1zC5JxqdE_0x2Lu_WYi2Xfke7VsiP3L5zngfA,15
|
|
35
|
+
sagemaker_core-1.0.17.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|