diracx-client 0.0.1a17__py3-none-any.whl → 0.0.1a19__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- diracx/client/__init__.py +4 -18
- diracx/client/aio.py +1 -0
- diracx/client/extensions.py +90 -0
- diracx/client/{aio → generated}/__init__.py +2 -2
- diracx/client/{_client.py → generated/_client.py} +7 -6
- diracx/client/{_configuration.py → generated/_configuration.py} +1 -1
- diracx/client/generated/_patch.py +47 -0
- diracx/client/{_serialization.py → generated/_serialization.py} +301 -151
- diracx/client/{_vendor.py → generated/_vendor.py} +1 -1
- diracx/client/generated/aio/__init__.py +21 -0
- diracx/client/{aio → generated/aio}/_client.py +7 -6
- diracx/client/{aio → generated/aio}/_configuration.py +1 -1
- diracx/client/generated/aio/_patch.py +23 -0
- diracx/client/{aio → generated/aio}/_vendor.py +1 -1
- diracx/client/{aio → generated/aio}/operations/__init__.py +1 -1
- diracx/client/{aio → generated/aio}/operations/_operations.py +402 -385
- diracx/client/{models → generated/models}/__init__.py +3 -1
- diracx/client/{models → generated/models}/_enums.py +2 -2
- diracx/client/{models → generated/models}/_models.py +84 -43
- diracx/client/{operations → generated/operations}/__init__.py +1 -1
- diracx/client/{operations → generated/operations}/_operations.py +402 -385
- diracx/client/generated/py.typed +1 -0
- diracx/client/models.py +5 -0
- diracx/client/patches/__init__.py +19 -0
- diracx/client/patches/aio/__init__.py +18 -0
- diracx/client/{aio/_patch.py → patches/aio/utils.py} +10 -19
- diracx/client/{_patch.py → patches/utils.py} +98 -121
- {diracx_client-0.0.1a17.dist-info → diracx_client-0.0.1a19.dist-info}/METADATA +4 -4
- diracx_client-0.0.1a19.dist-info/RECORD +36 -0
- {diracx_client-0.0.1a17.dist-info → diracx_client-0.0.1a19.dist-info}/WHEEL +1 -1
- diracx_client-0.0.1a19.dist-info/entry_points.txt +3 -0
- diracx_client-0.0.1a17.dist-info/RECORD +0 -26
- /diracx/client/{aio → generated/aio}/operations/_patch.py +0 -0
- /diracx/client/{models → generated/models}/_patch.py +0 -0
- /diracx/client/{operations → generated/operations}/_patch.py +0 -0
- {diracx_client-0.0.1a17.dist-info → diracx_client-0.0.1a19.dist-info}/top_level.txt +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
# pylint: disable=too-many-lines,too-many-statements
|
2
2
|
# coding=utf-8
|
3
3
|
# --------------------------------------------------------------------------
|
4
|
-
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.10.
|
4
|
+
# Code generated by Microsoft (R) AutoRest Code Generator (autorest: 3.10.0, generator: @autorest/python@6.23.0)
|
5
5
|
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
6
6
|
# --------------------------------------------------------------------------
|
7
7
|
from io import IOBase
|
@@ -918,7 +918,7 @@ class WellKnownOperations:
|
|
918
918
|
**DO NOT** instantiate this class directly.
|
919
919
|
|
920
920
|
Instead, you should access the following operations through
|
921
|
-
:class:`~
|
921
|
+
:class:`~generated.Dirac`'s
|
922
922
|
:attr:`well_known` attribute.
|
923
923
|
"""
|
924
924
|
|
@@ -943,12 +943,14 @@ class WellKnownOperations:
|
|
943
943
|
:rtype: any
|
944
944
|
:raises ~azure.core.exceptions.HttpResponseError:
|
945
945
|
"""
|
946
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
947
|
-
|
948
|
-
|
949
|
-
|
950
|
-
|
951
|
-
|
946
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
947
|
+
{ # pylint: disable=unsubscriptable-object
|
948
|
+
401: ClientAuthenticationError,
|
949
|
+
404: ResourceNotFoundError,
|
950
|
+
409: ResourceExistsError,
|
951
|
+
304: ResourceNotModifiedError,
|
952
|
+
}
|
953
|
+
)
|
952
954
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
953
955
|
|
954
956
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -972,14 +974,12 @@ class WellKnownOperations:
|
|
972
974
|
response = pipeline_response.http_response
|
973
975
|
|
974
976
|
if response.status_code not in [200]:
|
975
|
-
if _stream:
|
976
|
-
response.read() # Load the body in memory and close the socket
|
977
977
|
map_error(
|
978
978
|
status_code=response.status_code, response=response, error_map=error_map
|
979
979
|
)
|
980
980
|
raise HttpResponseError(response=response)
|
981
981
|
|
982
|
-
deserialized = self._deserialize("object", pipeline_response)
|
982
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
983
983
|
|
984
984
|
if cls:
|
985
985
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -993,15 +993,17 @@ class WellKnownOperations:
|
|
993
993
|
Get metadata about the dirac installation.
|
994
994
|
|
995
995
|
:return: Metadata
|
996
|
-
:rtype: ~
|
996
|
+
:rtype: ~generated.models.Metadata
|
997
997
|
:raises ~azure.core.exceptions.HttpResponseError:
|
998
998
|
"""
|
999
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1000
|
-
|
1001
|
-
|
1002
|
-
|
1003
|
-
|
1004
|
-
|
999
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1000
|
+
{ # pylint: disable=unsubscriptable-object
|
1001
|
+
401: ClientAuthenticationError,
|
1002
|
+
404: ResourceNotFoundError,
|
1003
|
+
409: ResourceExistsError,
|
1004
|
+
304: ResourceNotModifiedError,
|
1005
|
+
}
|
1006
|
+
)
|
1005
1007
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1006
1008
|
|
1007
1009
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1025,14 +1027,12 @@ class WellKnownOperations:
|
|
1025
1027
|
response = pipeline_response.http_response
|
1026
1028
|
|
1027
1029
|
if response.status_code not in [200]:
|
1028
|
-
if _stream:
|
1029
|
-
response.read() # Load the body in memory and close the socket
|
1030
1030
|
map_error(
|
1031
1031
|
status_code=response.status_code, response=response, error_map=error_map
|
1032
1032
|
)
|
1033
1033
|
raise HttpResponseError(response=response)
|
1034
1034
|
|
1035
|
-
deserialized = self._deserialize("Metadata", pipeline_response)
|
1035
|
+
deserialized = self._deserialize("Metadata", pipeline_response.http_response)
|
1036
1036
|
|
1037
1037
|
if cls:
|
1038
1038
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1046,7 +1046,7 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1046
1046
|
**DO NOT** instantiate this class directly.
|
1047
1047
|
|
1048
1048
|
Instead, you should access the following operations through
|
1049
|
-
:class:`~
|
1049
|
+
:class:`~generated.Dirac`'s
|
1050
1050
|
:attr:`auth` attribute.
|
1051
1051
|
"""
|
1052
1052
|
|
@@ -1077,7 +1077,7 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1077
1077
|
Initiate the device flow against DIRAC authorization Server.
|
1078
1078
|
Scope must have exactly up to one ``group`` (otherwise default) and
|
1079
1079
|
one or more ``property`` scope.
|
1080
|
-
If no property, then get default one
|
1080
|
+
If no property, then get default one.
|
1081
1081
|
|
1082
1082
|
Offers the user to go with the browser to
|
1083
1083
|
``auth/<vo>/device?user_code=XYZ``.
|
@@ -1087,15 +1087,17 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1087
1087
|
:keyword scope: Required.
|
1088
1088
|
:paramtype scope: str
|
1089
1089
|
:return: InitiateDeviceFlowResponse
|
1090
|
-
:rtype: ~
|
1090
|
+
:rtype: ~generated.models.InitiateDeviceFlowResponse
|
1091
1091
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1092
1092
|
"""
|
1093
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1094
|
-
|
1095
|
-
|
1096
|
-
|
1097
|
-
|
1098
|
-
|
1093
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1094
|
+
{ # pylint: disable=unsubscriptable-object
|
1095
|
+
401: ClientAuthenticationError,
|
1096
|
+
404: ResourceNotFoundError,
|
1097
|
+
409: ResourceExistsError,
|
1098
|
+
304: ResourceNotModifiedError,
|
1099
|
+
}
|
1100
|
+
)
|
1099
1101
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1100
1102
|
|
1101
1103
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1121,15 +1123,13 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1121
1123
|
response = pipeline_response.http_response
|
1122
1124
|
|
1123
1125
|
if response.status_code not in [200]:
|
1124
|
-
if _stream:
|
1125
|
-
response.read() # Load the body in memory and close the socket
|
1126
1126
|
map_error(
|
1127
1127
|
status_code=response.status_code, response=response, error_map=error_map
|
1128
1128
|
)
|
1129
1129
|
raise HttpResponseError(response=response)
|
1130
1130
|
|
1131
1131
|
deserialized = self._deserialize(
|
1132
|
-
"InitiateDeviceFlowResponse", pipeline_response
|
1132
|
+
"InitiateDeviceFlowResponse", pipeline_response.http_response
|
1133
1133
|
)
|
1134
1134
|
|
1135
1135
|
if cls:
|
@@ -1156,12 +1156,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1156
1156
|
:rtype: any
|
1157
1157
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1158
1158
|
"""
|
1159
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1160
|
-
|
1161
|
-
|
1162
|
-
|
1163
|
-
|
1164
|
-
|
1159
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1160
|
+
{ # pylint: disable=unsubscriptable-object
|
1161
|
+
401: ClientAuthenticationError,
|
1162
|
+
404: ResourceNotFoundError,
|
1163
|
+
409: ResourceExistsError,
|
1164
|
+
304: ResourceNotModifiedError,
|
1165
|
+
}
|
1166
|
+
)
|
1165
1167
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1166
1168
|
|
1167
1169
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1186,14 +1188,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1186
1188
|
response = pipeline_response.http_response
|
1187
1189
|
|
1188
1190
|
if response.status_code not in [200]:
|
1189
|
-
if _stream:
|
1190
|
-
response.read() # Load the body in memory and close the socket
|
1191
1191
|
map_error(
|
1192
1192
|
status_code=response.status_code, response=response, error_map=error_map
|
1193
1193
|
)
|
1194
1194
|
raise HttpResponseError(response=response)
|
1195
1195
|
|
1196
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1196
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1197
1197
|
|
1198
1198
|
if cls:
|
1199
1199
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1218,12 +1218,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1218
1218
|
:rtype: any
|
1219
1219
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1220
1220
|
"""
|
1221
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1222
|
-
|
1223
|
-
|
1224
|
-
|
1225
|
-
|
1226
|
-
|
1221
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1222
|
+
{ # pylint: disable=unsubscriptable-object
|
1223
|
+
401: ClientAuthenticationError,
|
1224
|
+
404: ResourceNotFoundError,
|
1225
|
+
409: ResourceExistsError,
|
1226
|
+
304: ResourceNotModifiedError,
|
1227
|
+
}
|
1228
|
+
)
|
1227
1229
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1228
1230
|
|
1229
1231
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1249,14 +1251,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1249
1251
|
response = pipeline_response.http_response
|
1250
1252
|
|
1251
1253
|
if response.status_code not in [200]:
|
1252
|
-
if _stream:
|
1253
|
-
response.read() # Load the body in memory and close the socket
|
1254
1254
|
map_error(
|
1255
1255
|
status_code=response.status_code, response=response, error_map=error_map
|
1256
1256
|
)
|
1257
1257
|
raise HttpResponseError(response=response)
|
1258
1258
|
|
1259
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1259
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1260
1260
|
|
1261
1261
|
if cls:
|
1262
1262
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1273,12 +1273,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1273
1273
|
:rtype: any
|
1274
1274
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1275
1275
|
"""
|
1276
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1277
|
-
|
1278
|
-
|
1279
|
-
|
1280
|
-
|
1281
|
-
|
1276
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1277
|
+
{ # pylint: disable=unsubscriptable-object
|
1278
|
+
401: ClientAuthenticationError,
|
1279
|
+
404: ResourceNotFoundError,
|
1280
|
+
409: ResourceExistsError,
|
1281
|
+
304: ResourceNotModifiedError,
|
1282
|
+
}
|
1283
|
+
)
|
1282
1284
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1283
1285
|
|
1284
1286
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1302,14 +1304,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1302
1304
|
response = pipeline_response.http_response
|
1303
1305
|
|
1304
1306
|
if response.status_code not in [200]:
|
1305
|
-
if _stream:
|
1306
|
-
response.read() # Load the body in memory and close the socket
|
1307
1307
|
map_error(
|
1308
1308
|
status_code=response.status_code, response=response, error_map=error_map
|
1309
1309
|
)
|
1310
1310
|
raise HttpResponseError(response=response)
|
1311
1311
|
|
1312
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1312
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1313
1313
|
|
1314
1314
|
if cls:
|
1315
1315
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1327,12 +1327,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1327
1327
|
:rtype: list[any]
|
1328
1328
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1329
1329
|
"""
|
1330
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1331
|
-
|
1332
|
-
|
1333
|
-
|
1334
|
-
|
1335
|
-
|
1330
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1331
|
+
{ # pylint: disable=unsubscriptable-object
|
1332
|
+
401: ClientAuthenticationError,
|
1333
|
+
404: ResourceNotFoundError,
|
1334
|
+
409: ResourceExistsError,
|
1335
|
+
304: ResourceNotModifiedError,
|
1336
|
+
}
|
1337
|
+
)
|
1336
1338
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1337
1339
|
|
1338
1340
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1356,14 +1358,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1356
1358
|
response = pipeline_response.http_response
|
1357
1359
|
|
1358
1360
|
if response.status_code not in [200]:
|
1359
|
-
if _stream:
|
1360
|
-
response.read() # Load the body in memory and close the socket
|
1361
1361
|
map_error(
|
1362
1362
|
status_code=response.status_code, response=response, error_map=error_map
|
1363
1363
|
)
|
1364
1364
|
raise HttpResponseError(response=response)
|
1365
1365
|
|
1366
|
-
deserialized = self._deserialize("[object]", pipeline_response)
|
1366
|
+
deserialized = self._deserialize("[object]", pipeline_response.http_response)
|
1367
1367
|
|
1368
1368
|
if cls:
|
1369
1369
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1383,12 +1383,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1383
1383
|
:rtype: str
|
1384
1384
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1385
1385
|
"""
|
1386
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1387
|
-
|
1388
|
-
|
1389
|
-
|
1390
|
-
|
1391
|
-
|
1386
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1387
|
+
{ # pylint: disable=unsubscriptable-object
|
1388
|
+
401: ClientAuthenticationError,
|
1389
|
+
404: ResourceNotFoundError,
|
1390
|
+
409: ResourceExistsError,
|
1391
|
+
304: ResourceNotModifiedError,
|
1392
|
+
}
|
1393
|
+
)
|
1392
1394
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1393
1395
|
|
1394
1396
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1413,14 +1415,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1413
1415
|
response = pipeline_response.http_response
|
1414
1416
|
|
1415
1417
|
if response.status_code not in [200]:
|
1416
|
-
if _stream:
|
1417
|
-
response.read() # Load the body in memory and close the socket
|
1418
1418
|
map_error(
|
1419
1419
|
status_code=response.status_code, response=response, error_map=error_map
|
1420
1420
|
)
|
1421
1421
|
raise HttpResponseError(response=response)
|
1422
1422
|
|
1423
|
-
deserialized = self._deserialize("str", pipeline_response)
|
1423
|
+
deserialized = self._deserialize("str", pipeline_response.http_response)
|
1424
1424
|
|
1425
1425
|
if cls:
|
1426
1426
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1434,15 +1434,17 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1434
1434
|
Get information about the user's identity.
|
1435
1435
|
|
1436
1436
|
:return: UserInfoResponse
|
1437
|
-
:rtype: ~
|
1437
|
+
:rtype: ~generated.models.UserInfoResponse
|
1438
1438
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1439
1439
|
"""
|
1440
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1441
|
-
|
1442
|
-
|
1443
|
-
|
1444
|
-
|
1445
|
-
|
1440
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1441
|
+
{ # pylint: disable=unsubscriptable-object
|
1442
|
+
401: ClientAuthenticationError,
|
1443
|
+
404: ResourceNotFoundError,
|
1444
|
+
409: ResourceExistsError,
|
1445
|
+
304: ResourceNotModifiedError,
|
1446
|
+
}
|
1447
|
+
)
|
1446
1448
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1447
1449
|
|
1448
1450
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1466,14 +1468,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1466
1468
|
response = pipeline_response.http_response
|
1467
1469
|
|
1468
1470
|
if response.status_code not in [200]:
|
1469
|
-
if _stream:
|
1470
|
-
response.read() # Load the body in memory and close the socket
|
1471
1471
|
map_error(
|
1472
1472
|
status_code=response.status_code, response=response, error_map=error_map
|
1473
1473
|
)
|
1474
1474
|
raise HttpResponseError(response=response)
|
1475
1475
|
|
1476
|
-
deserialized = self._deserialize(
|
1476
|
+
deserialized = self._deserialize(
|
1477
|
+
"UserInfoResponse", pipeline_response.http_response
|
1478
|
+
)
|
1477
1479
|
|
1478
1480
|
if cls:
|
1479
1481
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1504,11 +1506,11 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1504
1506
|
user authorize flow.
|
1505
1507
|
|
1506
1508
|
:keyword response_type: "code" Required.
|
1507
|
-
:paramtype response_type: str or ~
|
1509
|
+
:paramtype response_type: str or ~generated.models.Enum0
|
1508
1510
|
:keyword code_challenge: Required.
|
1509
1511
|
:paramtype code_challenge: str
|
1510
1512
|
:keyword code_challenge_method: "S256" Required.
|
1511
|
-
:paramtype code_challenge_method: str or ~
|
1513
|
+
:paramtype code_challenge_method: str or ~generated.models.Enum1
|
1512
1514
|
:keyword client_id: Required.
|
1513
1515
|
:paramtype client_id: str
|
1514
1516
|
:keyword redirect_uri: Required.
|
@@ -1521,12 +1523,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1521
1523
|
:rtype: any
|
1522
1524
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1523
1525
|
"""
|
1524
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1525
|
-
|
1526
|
-
|
1527
|
-
|
1528
|
-
|
1529
|
-
|
1526
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1527
|
+
{ # pylint: disable=unsubscriptable-object
|
1528
|
+
401: ClientAuthenticationError,
|
1529
|
+
404: ResourceNotFoundError,
|
1530
|
+
409: ResourceExistsError,
|
1531
|
+
304: ResourceNotModifiedError,
|
1532
|
+
}
|
1533
|
+
)
|
1530
1534
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1531
1535
|
|
1532
1536
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1557,14 +1561,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1557
1561
|
response = pipeline_response.http_response
|
1558
1562
|
|
1559
1563
|
if response.status_code not in [200]:
|
1560
|
-
if _stream:
|
1561
|
-
response.read() # Load the body in memory and close the socket
|
1562
1564
|
map_error(
|
1563
1565
|
status_code=response.status_code, response=response, error_map=error_map
|
1564
1566
|
)
|
1565
1567
|
raise HttpResponseError(response=response)
|
1566
1568
|
|
1567
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1569
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1568
1570
|
|
1569
1571
|
if cls:
|
1570
1572
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1593,12 +1595,14 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1593
1595
|
:rtype: any
|
1594
1596
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1595
1597
|
"""
|
1596
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1597
|
-
|
1598
|
-
|
1599
|
-
|
1600
|
-
|
1601
|
-
|
1598
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1599
|
+
{ # pylint: disable=unsubscriptable-object
|
1600
|
+
401: ClientAuthenticationError,
|
1601
|
+
404: ResourceNotFoundError,
|
1602
|
+
409: ResourceExistsError,
|
1603
|
+
304: ResourceNotModifiedError,
|
1604
|
+
}
|
1605
|
+
)
|
1602
1606
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1603
1607
|
|
1604
1608
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1624,14 +1628,12 @@ class AuthOperations: # pylint: disable=abstract-class-instantiated
|
|
1624
1628
|
response = pipeline_response.http_response
|
1625
1629
|
|
1626
1630
|
if response.status_code not in [200]:
|
1627
|
-
if _stream:
|
1628
|
-
response.read() # Load the body in memory and close the socket
|
1629
1631
|
map_error(
|
1630
1632
|
status_code=response.status_code, response=response, error_map=error_map
|
1631
1633
|
)
|
1632
1634
|
raise HttpResponseError(response=response)
|
1633
1635
|
|
1634
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1636
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1635
1637
|
|
1636
1638
|
if cls:
|
1637
1639
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1645,7 +1647,7 @@ class ConfigOperations:
|
|
1645
1647
|
**DO NOT** instantiate this class directly.
|
1646
1648
|
|
1647
1649
|
Instead, you should access the following operations through
|
1648
|
-
:class:`~
|
1650
|
+
:class:`~generated.Dirac`'s
|
1649
1651
|
:attr:`config` attribute.
|
1650
1652
|
"""
|
1651
1653
|
|
@@ -1689,12 +1691,14 @@ class ConfigOperations:
|
|
1689
1691
|
:rtype: any
|
1690
1692
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1691
1693
|
"""
|
1692
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1693
|
-
|
1694
|
-
|
1695
|
-
|
1696
|
-
|
1697
|
-
|
1694
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1695
|
+
{ # pylint: disable=unsubscriptable-object
|
1696
|
+
401: ClientAuthenticationError,
|
1697
|
+
404: ResourceNotFoundError,
|
1698
|
+
409: ResourceExistsError,
|
1699
|
+
304: ResourceNotModifiedError,
|
1700
|
+
}
|
1701
|
+
)
|
1698
1702
|
if match_condition == MatchConditions.IfNotModified:
|
1699
1703
|
error_map[412] = ResourceModifiedError
|
1700
1704
|
elif match_condition == MatchConditions.IfPresent:
|
@@ -1727,14 +1731,12 @@ class ConfigOperations:
|
|
1727
1731
|
response = pipeline_response.http_response
|
1728
1732
|
|
1729
1733
|
if response.status_code not in [200]:
|
1730
|
-
if _stream:
|
1731
|
-
response.read() # Load the body in memory and close the socket
|
1732
1734
|
map_error(
|
1733
1735
|
status_code=response.status_code, response=response, error_map=error_map
|
1734
1736
|
)
|
1735
1737
|
raise HttpResponseError(response=response)
|
1736
1738
|
|
1737
|
-
deserialized = self._deserialize("object", pipeline_response)
|
1739
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
1738
1740
|
|
1739
1741
|
if cls:
|
1740
1742
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1748,7 +1750,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1748
1750
|
**DO NOT** instantiate this class directly.
|
1749
1751
|
|
1750
1752
|
Instead, you should access the following operations through
|
1751
|
-
:class:`~
|
1753
|
+
:class:`~generated.Dirac`'s
|
1752
1754
|
:attr:`jobs` attribute.
|
1753
1755
|
"""
|
1754
1756
|
|
@@ -1782,12 +1784,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1782
1784
|
should be used to upload the sandbox to the storage backend.
|
1783
1785
|
|
1784
1786
|
:param body: Required.
|
1785
|
-
:type body: ~
|
1787
|
+
:type body: ~generated.models.SandboxInfo
|
1786
1788
|
:keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
|
1787
1789
|
Default value is "application/json".
|
1788
1790
|
:paramtype content_type: str
|
1789
1791
|
:return: SandboxUploadResponse
|
1790
|
-
:rtype: ~
|
1792
|
+
:rtype: ~generated.models.SandboxUploadResponse
|
1791
1793
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1792
1794
|
"""
|
1793
1795
|
|
@@ -1811,7 +1813,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1811
1813
|
Default value is "application/json".
|
1812
1814
|
:paramtype content_type: str
|
1813
1815
|
:return: SandboxUploadResponse
|
1814
|
-
:rtype: ~
|
1816
|
+
:rtype: ~generated.models.SandboxUploadResponse
|
1815
1817
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1816
1818
|
"""
|
1817
1819
|
|
@@ -1830,17 +1832,19 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1830
1832
|
should be used to upload the sandbox to the storage backend.
|
1831
1833
|
|
1832
1834
|
:param body: Is either a SandboxInfo type or a IO[bytes] type. Required.
|
1833
|
-
:type body: ~
|
1835
|
+
:type body: ~generated.models.SandboxInfo or IO[bytes]
|
1834
1836
|
:return: SandboxUploadResponse
|
1835
|
-
:rtype: ~
|
1837
|
+
:rtype: ~generated.models.SandboxUploadResponse
|
1836
1838
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1837
1839
|
"""
|
1838
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1839
|
-
|
1840
|
-
|
1841
|
-
|
1842
|
-
|
1843
|
-
|
1840
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1841
|
+
{ # pylint: disable=unsubscriptable-object
|
1842
|
+
401: ClientAuthenticationError,
|
1843
|
+
404: ResourceNotFoundError,
|
1844
|
+
409: ResourceExistsError,
|
1845
|
+
304: ResourceNotModifiedError,
|
1846
|
+
}
|
1847
|
+
)
|
1844
1848
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1845
1849
|
|
1846
1850
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -1878,14 +1882,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1878
1882
|
response = pipeline_response.http_response
|
1879
1883
|
|
1880
1884
|
if response.status_code not in [200]:
|
1881
|
-
if _stream:
|
1882
|
-
response.read() # Load the body in memory and close the socket
|
1883
1885
|
map_error(
|
1884
1886
|
status_code=response.status_code, response=response, error_map=error_map
|
1885
1887
|
)
|
1886
1888
|
raise HttpResponseError(response=response)
|
1887
1889
|
|
1888
|
-
deserialized = self._deserialize(
|
1890
|
+
deserialized = self._deserialize(
|
1891
|
+
"SandboxUploadResponse", pipeline_response.http_response
|
1892
|
+
)
|
1889
1893
|
|
1890
1894
|
if cls:
|
1891
1895
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1898,7 +1902,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1898
1902
|
) -> _models.SandboxDownloadResponse:
|
1899
1903
|
"""Get Sandbox File.
|
1900
1904
|
|
1901
|
-
Get a presigned URL to download a sandbox file
|
1905
|
+
Get a presigned URL to download a sandbox file.
|
1902
1906
|
|
1903
1907
|
This route cannot use a redirect response most clients will also send the
|
1904
1908
|
authorization header when following a redirect. This is not desirable as
|
@@ -1909,15 +1913,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1909
1913
|
:keyword pfn: Required.
|
1910
1914
|
:paramtype pfn: str
|
1911
1915
|
:return: SandboxDownloadResponse
|
1912
|
-
:rtype: ~
|
1916
|
+
:rtype: ~generated.models.SandboxDownloadResponse
|
1913
1917
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1914
1918
|
"""
|
1915
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1916
|
-
|
1917
|
-
|
1918
|
-
|
1919
|
-
|
1920
|
-
|
1919
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1920
|
+
{ # pylint: disable=unsubscriptable-object
|
1921
|
+
401: ClientAuthenticationError,
|
1922
|
+
404: ResourceNotFoundError,
|
1923
|
+
409: ResourceExistsError,
|
1924
|
+
304: ResourceNotModifiedError,
|
1925
|
+
}
|
1926
|
+
)
|
1921
1927
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1922
1928
|
|
1923
1929
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -1942,14 +1948,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1942
1948
|
response = pipeline_response.http_response
|
1943
1949
|
|
1944
1950
|
if response.status_code not in [200]:
|
1945
|
-
if _stream:
|
1946
|
-
response.read() # Load the body in memory and close the socket
|
1947
1951
|
map_error(
|
1948
1952
|
status_code=response.status_code, response=response, error_map=error_map
|
1949
1953
|
)
|
1950
1954
|
raise HttpResponseError(response=response)
|
1951
1955
|
|
1952
|
-
deserialized = self._deserialize(
|
1956
|
+
deserialized = self._deserialize(
|
1957
|
+
"SandboxDownloadResponse", pipeline_response.http_response
|
1958
|
+
)
|
1953
1959
|
|
1954
1960
|
if cls:
|
1955
1961
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -1970,12 +1976,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
1970
1976
|
:rtype: any
|
1971
1977
|
:raises ~azure.core.exceptions.HttpResponseError:
|
1972
1978
|
"""
|
1973
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
1974
|
-
|
1975
|
-
|
1976
|
-
|
1977
|
-
|
1978
|
-
|
1979
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
1980
|
+
{ # pylint: disable=unsubscriptable-object
|
1981
|
+
401: ClientAuthenticationError,
|
1982
|
+
404: ResourceNotFoundError,
|
1983
|
+
409: ResourceExistsError,
|
1984
|
+
304: ResourceNotModifiedError,
|
1985
|
+
}
|
1986
|
+
)
|
1979
1987
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
1980
1988
|
|
1981
1989
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2000,14 +2008,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2000
2008
|
response = pipeline_response.http_response
|
2001
2009
|
|
2002
2010
|
if response.status_code not in [200]:
|
2003
|
-
if _stream:
|
2004
|
-
response.read() # Load the body in memory and close the socket
|
2005
2011
|
map_error(
|
2006
2012
|
status_code=response.status_code, response=response, error_map=error_map
|
2007
2013
|
)
|
2008
2014
|
raise HttpResponseError(response=response)
|
2009
2015
|
|
2010
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2016
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2011
2017
|
|
2012
2018
|
if cls:
|
2013
2019
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2026,12 +2032,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2026
2032
|
:rtype: dict[str, list[any]]
|
2027
2033
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2028
2034
|
"""
|
2029
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2030
|
-
|
2031
|
-
|
2032
|
-
|
2033
|
-
|
2034
|
-
|
2035
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2036
|
+
{ # pylint: disable=unsubscriptable-object
|
2037
|
+
401: ClientAuthenticationError,
|
2038
|
+
404: ResourceNotFoundError,
|
2039
|
+
409: ResourceExistsError,
|
2040
|
+
304: ResourceNotModifiedError,
|
2041
|
+
}
|
2042
|
+
)
|
2035
2043
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2036
2044
|
|
2037
2045
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2056,14 +2064,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2056
2064
|
response = pipeline_response.http_response
|
2057
2065
|
|
2058
2066
|
if response.status_code not in [200]:
|
2059
|
-
if _stream:
|
2060
|
-
response.read() # Load the body in memory and close the socket
|
2061
2067
|
map_error(
|
2062
2068
|
status_code=response.status_code, response=response, error_map=error_map
|
2063
2069
|
)
|
2064
2070
|
raise HttpResponseError(response=response)
|
2065
2071
|
|
2066
|
-
deserialized = self._deserialize("{[object]}", pipeline_response)
|
2072
|
+
deserialized = self._deserialize("{[object]}", pipeline_response.http_response)
|
2067
2073
|
|
2068
2074
|
if cls:
|
2069
2075
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2082,12 +2088,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2082
2088
|
:rtype: any
|
2083
2089
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2084
2090
|
"""
|
2085
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2086
|
-
|
2087
|
-
|
2088
|
-
|
2089
|
-
|
2090
|
-
|
2091
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2092
|
+
{ # pylint: disable=unsubscriptable-object
|
2093
|
+
401: ClientAuthenticationError,
|
2094
|
+
404: ResourceNotFoundError,
|
2095
|
+
409: ResourceExistsError,
|
2096
|
+
304: ResourceNotModifiedError,
|
2097
|
+
}
|
2098
|
+
)
|
2091
2099
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2092
2100
|
|
2093
2101
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2112,14 +2120,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2112
2120
|
response = pipeline_response.http_response
|
2113
2121
|
|
2114
2122
|
if response.status_code not in [200]:
|
2115
|
-
if _stream:
|
2116
|
-
response.read() # Load the body in memory and close the socket
|
2117
2123
|
map_error(
|
2118
2124
|
status_code=response.status_code, response=response, error_map=error_map
|
2119
2125
|
)
|
2120
2126
|
raise HttpResponseError(response=response)
|
2121
2127
|
|
2122
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2128
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2123
2129
|
|
2124
2130
|
if cls:
|
2125
2131
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2137,17 +2143,19 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2137
2143
|
:param job_id: Required.
|
2138
2144
|
:type job_id: int
|
2139
2145
|
:param sandbox_type: Known values are: "input" and "output". Required.
|
2140
|
-
:type sandbox_type: str or ~
|
2146
|
+
:type sandbox_type: str or ~generated.models.SandboxType
|
2141
2147
|
:return: list of any
|
2142
2148
|
:rtype: list[any]
|
2143
2149
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2144
2150
|
"""
|
2145
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2146
|
-
|
2147
|
-
|
2148
|
-
|
2149
|
-
|
2150
|
-
|
2151
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2152
|
+
{ # pylint: disable=unsubscriptable-object
|
2153
|
+
401: ClientAuthenticationError,
|
2154
|
+
404: ResourceNotFoundError,
|
2155
|
+
409: ResourceExistsError,
|
2156
|
+
304: ResourceNotModifiedError,
|
2157
|
+
}
|
2158
|
+
)
|
2151
2159
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2152
2160
|
|
2153
2161
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2173,14 +2181,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2173
2181
|
response = pipeline_response.http_response
|
2174
2182
|
|
2175
2183
|
if response.status_code not in [200]:
|
2176
|
-
if _stream:
|
2177
|
-
response.read() # Load the body in memory and close the socket
|
2178
2184
|
map_error(
|
2179
2185
|
status_code=response.status_code, response=response, error_map=error_map
|
2180
2186
|
)
|
2181
2187
|
raise HttpResponseError(response=response)
|
2182
2188
|
|
2183
|
-
deserialized = self._deserialize("[object]", pipeline_response)
|
2189
|
+
deserialized = self._deserialize("[object]", pipeline_response.http_response)
|
2184
2190
|
|
2185
2191
|
if cls:
|
2186
2192
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2201,12 +2207,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2201
2207
|
:rtype: any
|
2202
2208
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2203
2209
|
"""
|
2204
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2205
|
-
|
2206
|
-
|
2207
|
-
|
2208
|
-
|
2209
|
-
|
2210
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2211
|
+
{ # pylint: disable=unsubscriptable-object
|
2212
|
+
401: ClientAuthenticationError,
|
2213
|
+
404: ResourceNotFoundError,
|
2214
|
+
409: ResourceExistsError,
|
2215
|
+
304: ResourceNotModifiedError,
|
2216
|
+
}
|
2217
|
+
)
|
2210
2218
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2211
2219
|
|
2212
2220
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -2238,14 +2246,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2238
2246
|
response = pipeline_response.http_response
|
2239
2247
|
|
2240
2248
|
if response.status_code not in [200]:
|
2241
|
-
if _stream:
|
2242
|
-
response.read() # Load the body in memory and close the socket
|
2243
2249
|
map_error(
|
2244
2250
|
status_code=response.status_code, response=response, error_map=error_map
|
2245
2251
|
)
|
2246
2252
|
raise HttpResponseError(response=response)
|
2247
2253
|
|
2248
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2254
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2249
2255
|
|
2250
2256
|
if cls:
|
2251
2257
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2266,7 +2272,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2266
2272
|
Default value is "application/json".
|
2267
2273
|
:paramtype content_type: str
|
2268
2274
|
:return: list of InsertedJob
|
2269
|
-
:rtype: list[~
|
2275
|
+
:rtype: list[~generated.models.InsertedJob]
|
2270
2276
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2271
2277
|
"""
|
2272
2278
|
|
@@ -2284,7 +2290,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2284
2290
|
Default value is "application/json".
|
2285
2291
|
:paramtype content_type: str
|
2286
2292
|
:return: list of InsertedJob
|
2287
|
-
:rtype: list[~
|
2293
|
+
:rtype: list[~generated.models.InsertedJob]
|
2288
2294
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2289
2295
|
"""
|
2290
2296
|
|
@@ -2299,15 +2305,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2299
2305
|
:param body: Is either a [str] type or a IO[bytes] type. Required.
|
2300
2306
|
:type body: list[str] or IO[bytes]
|
2301
2307
|
:return: list of InsertedJob
|
2302
|
-
:rtype: list[~
|
2308
|
+
:rtype: list[~generated.models.InsertedJob]
|
2303
2309
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2304
2310
|
"""
|
2305
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2306
|
-
|
2307
|
-
|
2308
|
-
|
2309
|
-
|
2310
|
-
|
2311
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2312
|
+
{ # pylint: disable=unsubscriptable-object
|
2313
|
+
401: ClientAuthenticationError,
|
2314
|
+
404: ResourceNotFoundError,
|
2315
|
+
409: ResourceExistsError,
|
2316
|
+
304: ResourceNotModifiedError,
|
2317
|
+
}
|
2318
|
+
)
|
2311
2319
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2312
2320
|
|
2313
2321
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -2345,14 +2353,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2345
2353
|
response = pipeline_response.http_response
|
2346
2354
|
|
2347
2355
|
if response.status_code not in [200]:
|
2348
|
-
if _stream:
|
2349
|
-
response.read() # Load the body in memory and close the socket
|
2350
2356
|
map_error(
|
2351
2357
|
status_code=response.status_code, response=response, error_map=error_map
|
2352
2358
|
)
|
2353
2359
|
raise HttpResponseError(response=response)
|
2354
2360
|
|
2355
|
-
deserialized = self._deserialize(
|
2361
|
+
deserialized = self._deserialize(
|
2362
|
+
"[InsertedJob]", pipeline_response.http_response
|
2363
|
+
)
|
2356
2364
|
|
2357
2365
|
if cls:
|
2358
2366
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2371,12 +2379,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2371
2379
|
:rtype: any
|
2372
2380
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2373
2381
|
"""
|
2374
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2375
|
-
|
2376
|
-
|
2377
|
-
|
2378
|
-
|
2379
|
-
|
2382
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2383
|
+
{ # pylint: disable=unsubscriptable-object
|
2384
|
+
401: ClientAuthenticationError,
|
2385
|
+
404: ResourceNotFoundError,
|
2386
|
+
409: ResourceExistsError,
|
2387
|
+
304: ResourceNotModifiedError,
|
2388
|
+
}
|
2389
|
+
)
|
2380
2390
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2381
2391
|
|
2382
2392
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2401,14 +2411,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2401
2411
|
response = pipeline_response.http_response
|
2402
2412
|
|
2403
2413
|
if response.status_code not in [200]:
|
2404
|
-
if _stream:
|
2405
|
-
response.read() # Load the body in memory and close the socket
|
2406
2414
|
map_error(
|
2407
2415
|
status_code=response.status_code, response=response, error_map=error_map
|
2408
2416
|
)
|
2409
2417
|
raise HttpResponseError(response=response)
|
2410
2418
|
|
2411
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2419
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2412
2420
|
|
2413
2421
|
if cls:
|
2414
2422
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2427,12 +2435,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2427
2435
|
:rtype: any
|
2428
2436
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2429
2437
|
"""
|
2430
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2431
|
-
|
2432
|
-
|
2433
|
-
|
2434
|
-
|
2435
|
-
|
2438
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2439
|
+
{ # pylint: disable=unsubscriptable-object
|
2440
|
+
401: ClientAuthenticationError,
|
2441
|
+
404: ResourceNotFoundError,
|
2442
|
+
409: ResourceExistsError,
|
2443
|
+
304: ResourceNotModifiedError,
|
2444
|
+
}
|
2445
|
+
)
|
2436
2446
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2437
2447
|
|
2438
2448
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2457,14 +2467,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2457
2467
|
response = pipeline_response.http_response
|
2458
2468
|
|
2459
2469
|
if response.status_code not in [200]:
|
2460
|
-
if _stream:
|
2461
|
-
response.read() # Load the body in memory and close the socket
|
2462
2470
|
map_error(
|
2463
2471
|
status_code=response.status_code, response=response, error_map=error_map
|
2464
2472
|
)
|
2465
2473
|
raise HttpResponseError(response=response)
|
2466
2474
|
|
2467
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2475
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2468
2476
|
|
2469
2477
|
if cls:
|
2470
2478
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2487,12 +2495,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2487
2495
|
:rtype: any
|
2488
2496
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2489
2497
|
"""
|
2490
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2491
|
-
|
2492
|
-
|
2493
|
-
|
2494
|
-
|
2495
|
-
|
2498
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2499
|
+
{ # pylint: disable=unsubscriptable-object
|
2500
|
+
401: ClientAuthenticationError,
|
2501
|
+
404: ResourceNotFoundError,
|
2502
|
+
409: ResourceExistsError,
|
2503
|
+
304: ResourceNotModifiedError,
|
2504
|
+
}
|
2505
|
+
)
|
2496
2506
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2497
2507
|
|
2498
2508
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2517,14 +2527,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2517
2527
|
response = pipeline_response.http_response
|
2518
2528
|
|
2519
2529
|
if response.status_code not in [200]:
|
2520
|
-
if _stream:
|
2521
|
-
response.read() # Load the body in memory and close the socket
|
2522
2530
|
map_error(
|
2523
2531
|
status_code=response.status_code, response=response, error_map=error_map
|
2524
2532
|
)
|
2525
2533
|
raise HttpResponseError(response=response)
|
2526
2534
|
|
2527
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2535
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2528
2536
|
|
2529
2537
|
if cls:
|
2530
2538
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2542,15 +2550,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2542
2550
|
:keyword job_ids: Required.
|
2543
2551
|
:paramtype job_ids: list[int]
|
2544
2552
|
:return: dict mapping str to LimitedJobStatusReturn
|
2545
|
-
:rtype: dict[str, ~
|
2553
|
+
:rtype: dict[str, ~generated.models.LimitedJobStatusReturn]
|
2546
2554
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2547
2555
|
"""
|
2548
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2549
|
-
|
2550
|
-
|
2551
|
-
|
2552
|
-
|
2553
|
-
|
2556
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2557
|
+
{ # pylint: disable=unsubscriptable-object
|
2558
|
+
401: ClientAuthenticationError,
|
2559
|
+
404: ResourceNotFoundError,
|
2560
|
+
409: ResourceExistsError,
|
2561
|
+
304: ResourceNotModifiedError,
|
2562
|
+
}
|
2563
|
+
)
|
2554
2564
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2555
2565
|
|
2556
2566
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2577,14 +2587,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2577
2587
|
response = pipeline_response.http_response
|
2578
2588
|
|
2579
2589
|
if response.status_code not in [200]:
|
2580
|
-
if _stream:
|
2581
|
-
response.read() # Load the body in memory and close the socket
|
2582
2590
|
map_error(
|
2583
2591
|
status_code=response.status_code, response=response, error_map=error_map
|
2584
2592
|
)
|
2585
2593
|
raise HttpResponseError(response=response)
|
2586
2594
|
|
2587
|
-
deserialized = self._deserialize(
|
2595
|
+
deserialized = self._deserialize(
|
2596
|
+
"{LimitedJobStatusReturn}", pipeline_response.http_response
|
2597
|
+
)
|
2588
2598
|
|
2589
2599
|
if cls:
|
2590
2600
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2605,14 +2615,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2605
2615
|
Set Job Status Bulk.
|
2606
2616
|
|
2607
2617
|
:param body: Required.
|
2608
|
-
:type body: dict[str, dict[str, ~
|
2618
|
+
:type body: dict[str, dict[str, ~generated.models.JobStatusUpdate]]
|
2609
2619
|
:keyword force: Default value is False.
|
2610
2620
|
:paramtype force: bool
|
2611
2621
|
:keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
|
2612
2622
|
Default value is "application/json".
|
2613
2623
|
:paramtype content_type: str
|
2614
2624
|
:return: dict mapping str to SetJobStatusReturn
|
2615
|
-
:rtype: dict[str, ~
|
2625
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
2616
2626
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2617
2627
|
"""
|
2618
2628
|
|
@@ -2637,7 +2647,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2637
2647
|
Default value is "application/json".
|
2638
2648
|
:paramtype content_type: str
|
2639
2649
|
:return: dict mapping str to SetJobStatusReturn
|
2640
|
-
:rtype: dict[str, ~
|
2650
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
2641
2651
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2642
2652
|
"""
|
2643
2653
|
|
@@ -2654,19 +2664,21 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2654
2664
|
Set Job Status Bulk.
|
2655
2665
|
|
2656
2666
|
:param body: Is either a {str: {str: JobStatusUpdate}} type or a IO[bytes] type. Required.
|
2657
|
-
:type body: dict[str, dict[str, ~
|
2667
|
+
:type body: dict[str, dict[str, ~generated.models.JobStatusUpdate]] or IO[bytes]
|
2658
2668
|
:keyword force: Default value is False.
|
2659
2669
|
:paramtype force: bool
|
2660
2670
|
:return: dict mapping str to SetJobStatusReturn
|
2661
|
-
:rtype: dict[str, ~
|
2671
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
2662
2672
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2663
2673
|
"""
|
2664
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2665
|
-
|
2666
|
-
|
2667
|
-
|
2668
|
-
|
2669
|
-
|
2674
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2675
|
+
{ # pylint: disable=unsubscriptable-object
|
2676
|
+
401: ClientAuthenticationError,
|
2677
|
+
404: ResourceNotFoundError,
|
2678
|
+
409: ResourceExistsError,
|
2679
|
+
304: ResourceNotModifiedError,
|
2680
|
+
}
|
2681
|
+
)
|
2670
2682
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2671
2683
|
|
2672
2684
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -2705,14 +2717,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2705
2717
|
response = pipeline_response.http_response
|
2706
2718
|
|
2707
2719
|
if response.status_code not in [200]:
|
2708
|
-
if _stream:
|
2709
|
-
response.read() # Load the body in memory and close the socket
|
2710
2720
|
map_error(
|
2711
2721
|
status_code=response.status_code, response=response, error_map=error_map
|
2712
2722
|
)
|
2713
2723
|
raise HttpResponseError(response=response)
|
2714
2724
|
|
2715
|
-
deserialized = self._deserialize(
|
2725
|
+
deserialized = self._deserialize(
|
2726
|
+
"{SetJobStatusReturn}", pipeline_response.http_response
|
2727
|
+
)
|
2716
2728
|
|
2717
2729
|
if cls:
|
2718
2730
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2730,15 +2742,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2730
2742
|
:keyword job_ids: Required.
|
2731
2743
|
:paramtype job_ids: list[int]
|
2732
2744
|
:return: dict mapping str to list of JobStatusReturn
|
2733
|
-
:rtype: dict[str, list[~
|
2745
|
+
:rtype: dict[str, list[~generated.models.JobStatusReturn]]
|
2734
2746
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2735
2747
|
"""
|
2736
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2737
|
-
|
2738
|
-
|
2739
|
-
|
2740
|
-
|
2741
|
-
|
2748
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2749
|
+
{ # pylint: disable=unsubscriptable-object
|
2750
|
+
401: ClientAuthenticationError,
|
2751
|
+
404: ResourceNotFoundError,
|
2752
|
+
409: ResourceExistsError,
|
2753
|
+
304: ResourceNotModifiedError,
|
2754
|
+
}
|
2755
|
+
)
|
2742
2756
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2743
2757
|
|
2744
2758
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2763,14 +2777,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2763
2777
|
response = pipeline_response.http_response
|
2764
2778
|
|
2765
2779
|
if response.status_code not in [200]:
|
2766
|
-
if _stream:
|
2767
|
-
response.read() # Load the body in memory and close the socket
|
2768
2780
|
map_error(
|
2769
2781
|
status_code=response.status_code, response=response, error_map=error_map
|
2770
2782
|
)
|
2771
2783
|
raise HttpResponseError(response=response)
|
2772
2784
|
|
2773
|
-
deserialized = self._deserialize(
|
2785
|
+
deserialized = self._deserialize(
|
2786
|
+
"{[JobStatusReturn]}", pipeline_response.http_response
|
2787
|
+
)
|
2774
2788
|
|
2775
2789
|
if cls:
|
2776
2790
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2789,12 +2803,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2789
2803
|
:rtype: any
|
2790
2804
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2791
2805
|
"""
|
2792
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2793
|
-
|
2794
|
-
|
2795
|
-
|
2796
|
-
|
2797
|
-
|
2806
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2807
|
+
{ # pylint: disable=unsubscriptable-object
|
2808
|
+
401: ClientAuthenticationError,
|
2809
|
+
404: ResourceNotFoundError,
|
2810
|
+
409: ResourceExistsError,
|
2811
|
+
304: ResourceNotModifiedError,
|
2812
|
+
}
|
2813
|
+
)
|
2798
2814
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2799
2815
|
|
2800
2816
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2819,14 +2835,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2819
2835
|
response = pipeline_response.http_response
|
2820
2836
|
|
2821
2837
|
if response.status_code not in [200]:
|
2822
|
-
if _stream:
|
2823
|
-
response.read() # Load the body in memory and close the socket
|
2824
2838
|
map_error(
|
2825
2839
|
status_code=response.status_code, response=response, error_map=error_map
|
2826
2840
|
)
|
2827
2841
|
raise HttpResponseError(response=response)
|
2828
2842
|
|
2829
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2843
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2830
2844
|
|
2831
2845
|
if cls:
|
2832
2846
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2845,12 +2859,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2845
2859
|
:rtype: any
|
2846
2860
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2847
2861
|
"""
|
2848
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2849
|
-
|
2850
|
-
|
2851
|
-
|
2852
|
-
|
2853
|
-
|
2862
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2863
|
+
{ # pylint: disable=unsubscriptable-object
|
2864
|
+
401: ClientAuthenticationError,
|
2865
|
+
404: ResourceNotFoundError,
|
2866
|
+
409: ResourceExistsError,
|
2867
|
+
304: ResourceNotModifiedError,
|
2868
|
+
}
|
2869
|
+
)
|
2854
2870
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2855
2871
|
|
2856
2872
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -2875,14 +2891,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2875
2891
|
response = pipeline_response.http_response
|
2876
2892
|
|
2877
2893
|
if response.status_code not in [200]:
|
2878
|
-
if _stream:
|
2879
|
-
response.read() # Load the body in memory and close the socket
|
2880
2894
|
map_error(
|
2881
2895
|
status_code=response.status_code, response=response, error_map=error_map
|
2882
2896
|
)
|
2883
2897
|
raise HttpResponseError(response=response)
|
2884
2898
|
|
2885
|
-
deserialized = self._deserialize("object", pipeline_response)
|
2899
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
2886
2900
|
|
2887
2901
|
if cls:
|
2888
2902
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -2906,7 +2920,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2906
2920
|
**TODO: Add more docs**.
|
2907
2921
|
|
2908
2922
|
:param body: Default value is None.
|
2909
|
-
:type body: ~
|
2923
|
+
:type body: ~generated.models.JobSearchParams
|
2910
2924
|
:keyword page: Default value is 1.
|
2911
2925
|
:paramtype page: int
|
2912
2926
|
:keyword per_page: Default value is 100.
|
@@ -2965,7 +2979,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2965
2979
|
**TODO: Add more docs**.
|
2966
2980
|
|
2967
2981
|
:param body: Is either a JobSearchParams type or a IO[bytes] type. Default value is None.
|
2968
|
-
:type body: ~
|
2982
|
+
:type body: ~generated.models.JobSearchParams or IO[bytes]
|
2969
2983
|
:keyword page: Default value is 1.
|
2970
2984
|
:paramtype page: int
|
2971
2985
|
:keyword per_page: Default value is 100.
|
@@ -2974,12 +2988,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
2974
2988
|
:rtype: list[JSON]
|
2975
2989
|
:raises ~azure.core.exceptions.HttpResponseError:
|
2976
2990
|
"""
|
2977
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
2978
|
-
|
2979
|
-
|
2980
|
-
|
2981
|
-
|
2982
|
-
|
2991
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
2992
|
+
{ # pylint: disable=unsubscriptable-object
|
2993
|
+
401: ClientAuthenticationError,
|
2994
|
+
404: ResourceNotFoundError,
|
2995
|
+
409: ResourceExistsError,
|
2996
|
+
304: ResourceNotModifiedError,
|
2997
|
+
}
|
2998
|
+
)
|
2983
2999
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
2984
3000
|
|
2985
3001
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -3022,23 +3038,18 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3022
3038
|
response = pipeline_response.http_response
|
3023
3039
|
|
3024
3040
|
if response.status_code not in [200, 206]:
|
3025
|
-
if _stream:
|
3026
|
-
response.read() # Load the body in memory and close the socket
|
3027
3041
|
map_error(
|
3028
3042
|
status_code=response.status_code, response=response, error_map=error_map
|
3029
3043
|
)
|
3030
3044
|
raise HttpResponseError(response=response)
|
3031
3045
|
|
3032
3046
|
response_headers = {}
|
3033
|
-
if response.status_code == 200:
|
3034
|
-
deserialized = self._deserialize("[object]", pipeline_response)
|
3035
|
-
|
3036
3047
|
if response.status_code == 206:
|
3037
3048
|
response_headers["Content-Range"] = self._deserialize(
|
3038
3049
|
"str", response.headers.get("Content-Range")
|
3039
3050
|
)
|
3040
3051
|
|
3041
|
-
|
3052
|
+
deserialized = self._deserialize("[object]", pipeline_response.http_response)
|
3042
3053
|
|
3043
3054
|
if cls:
|
3044
3055
|
return cls(pipeline_response, deserialized, response_headers) # type: ignore
|
@@ -3058,7 +3069,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3058
3069
|
Show information suitable for plotting.
|
3059
3070
|
|
3060
3071
|
:param body: Required.
|
3061
|
-
:type body: ~
|
3072
|
+
:type body: ~generated.models.JobSummaryParams
|
3062
3073
|
:keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
|
3063
3074
|
Default value is "application/json".
|
3064
3075
|
:paramtype content_type: str
|
@@ -3094,17 +3105,19 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3094
3105
|
Show information suitable for plotting.
|
3095
3106
|
|
3096
3107
|
:param body: Is either a JobSummaryParams type or a IO[bytes] type. Required.
|
3097
|
-
:type body: ~
|
3108
|
+
:type body: ~generated.models.JobSummaryParams or IO[bytes]
|
3098
3109
|
:return: any
|
3099
3110
|
:rtype: any
|
3100
3111
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3101
3112
|
"""
|
3102
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3103
|
-
|
3104
|
-
|
3105
|
-
|
3106
|
-
|
3107
|
-
|
3113
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3114
|
+
{ # pylint: disable=unsubscriptable-object
|
3115
|
+
401: ClientAuthenticationError,
|
3116
|
+
404: ResourceNotFoundError,
|
3117
|
+
409: ResourceExistsError,
|
3118
|
+
304: ResourceNotModifiedError,
|
3119
|
+
}
|
3120
|
+
)
|
3108
3121
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3109
3122
|
|
3110
3123
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -3142,14 +3155,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3142
3155
|
response = pipeline_response.http_response
|
3143
3156
|
|
3144
3157
|
if response.status_code not in [200]:
|
3145
|
-
if _stream:
|
3146
|
-
response.read() # Load the body in memory and close the socket
|
3147
3158
|
map_error(
|
3148
3159
|
status_code=response.status_code, response=response, error_map=error_map
|
3149
3160
|
)
|
3150
3161
|
raise HttpResponseError(response=response)
|
3151
3162
|
|
3152
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3163
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3153
3164
|
|
3154
3165
|
if cls:
|
3155
3166
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3168,12 +3179,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3168
3179
|
:rtype: any
|
3169
3180
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3170
3181
|
"""
|
3171
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3172
|
-
|
3173
|
-
|
3174
|
-
|
3175
|
-
|
3176
|
-
|
3182
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3183
|
+
{ # pylint: disable=unsubscriptable-object
|
3184
|
+
401: ClientAuthenticationError,
|
3185
|
+
404: ResourceNotFoundError,
|
3186
|
+
409: ResourceExistsError,
|
3187
|
+
304: ResourceNotModifiedError,
|
3188
|
+
}
|
3189
|
+
)
|
3177
3190
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3178
3191
|
|
3179
3192
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3198,14 +3211,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3198
3211
|
response = pipeline_response.http_response
|
3199
3212
|
|
3200
3213
|
if response.status_code not in [200]:
|
3201
|
-
if _stream:
|
3202
|
-
response.read() # Load the body in memory and close the socket
|
3203
3214
|
map_error(
|
3204
3215
|
status_code=response.status_code, response=response, error_map=error_map
|
3205
3216
|
)
|
3206
3217
|
raise HttpResponseError(response=response)
|
3207
3218
|
|
3208
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3219
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3209
3220
|
|
3210
3221
|
if cls:
|
3211
3222
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3224,12 +3235,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3224
3235
|
:rtype: any
|
3225
3236
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3226
3237
|
"""
|
3227
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3228
|
-
|
3229
|
-
|
3230
|
-
|
3231
|
-
|
3232
|
-
|
3238
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3239
|
+
{ # pylint: disable=unsubscriptable-object
|
3240
|
+
401: ClientAuthenticationError,
|
3241
|
+
404: ResourceNotFoundError,
|
3242
|
+
409: ResourceExistsError,
|
3243
|
+
304: ResourceNotModifiedError,
|
3244
|
+
}
|
3245
|
+
)
|
3233
3246
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3234
3247
|
|
3235
3248
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3254,14 +3267,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3254
3267
|
response = pipeline_response.http_response
|
3255
3268
|
|
3256
3269
|
if response.status_code not in [200]:
|
3257
|
-
if _stream:
|
3258
|
-
response.read() # Load the body in memory and close the socket
|
3259
3270
|
map_error(
|
3260
3271
|
status_code=response.status_code, response=response, error_map=error_map
|
3261
3272
|
)
|
3262
3273
|
raise HttpResponseError(response=response)
|
3263
3274
|
|
3264
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3275
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3265
3276
|
|
3266
3277
|
if cls:
|
3267
3278
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3286,12 +3297,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3286
3297
|
:rtype: any
|
3287
3298
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3288
3299
|
"""
|
3289
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3290
|
-
|
3291
|
-
|
3292
|
-
|
3293
|
-
|
3294
|
-
|
3300
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3301
|
+
{ # pylint: disable=unsubscriptable-object
|
3302
|
+
401: ClientAuthenticationError,
|
3303
|
+
404: ResourceNotFoundError,
|
3304
|
+
409: ResourceExistsError,
|
3305
|
+
304: ResourceNotModifiedError,
|
3306
|
+
}
|
3307
|
+
)
|
3295
3308
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3296
3309
|
|
3297
3310
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -3324,14 +3337,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3324
3337
|
response = pipeline_response.http_response
|
3325
3338
|
|
3326
3339
|
if response.status_code not in [200]:
|
3327
|
-
if _stream:
|
3328
|
-
response.read() # Load the body in memory and close the socket
|
3329
3340
|
map_error(
|
3330
3341
|
status_code=response.status_code, response=response, error_map=error_map
|
3331
3342
|
)
|
3332
3343
|
raise HttpResponseError(response=response)
|
3333
3344
|
|
3334
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3345
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3335
3346
|
|
3336
3347
|
if cls:
|
3337
3348
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3350,12 +3361,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3350
3361
|
:rtype: any
|
3351
3362
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3352
3363
|
"""
|
3353
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3354
|
-
|
3355
|
-
|
3356
|
-
|
3357
|
-
|
3358
|
-
|
3364
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3365
|
+
{ # pylint: disable=unsubscriptable-object
|
3366
|
+
401: ClientAuthenticationError,
|
3367
|
+
404: ResourceNotFoundError,
|
3368
|
+
409: ResourceExistsError,
|
3369
|
+
304: ResourceNotModifiedError,
|
3370
|
+
}
|
3371
|
+
)
|
3359
3372
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3360
3373
|
|
3361
3374
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3380,14 +3393,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3380
3393
|
response = pipeline_response.http_response
|
3381
3394
|
|
3382
3395
|
if response.status_code not in [200]:
|
3383
|
-
if _stream:
|
3384
|
-
response.read() # Load the body in memory and close the socket
|
3385
3396
|
map_error(
|
3386
3397
|
status_code=response.status_code, response=response, error_map=error_map
|
3387
3398
|
)
|
3388
3399
|
raise HttpResponseError(response=response)
|
3389
3400
|
|
3390
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3401
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3391
3402
|
|
3392
3403
|
if cls:
|
3393
3404
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3410,12 +3421,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3410
3421
|
:rtype: any
|
3411
3422
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3412
3423
|
"""
|
3413
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3414
|
-
|
3415
|
-
|
3416
|
-
|
3417
|
-
|
3418
|
-
|
3424
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3425
|
+
{ # pylint: disable=unsubscriptable-object
|
3426
|
+
401: ClientAuthenticationError,
|
3427
|
+
404: ResourceNotFoundError,
|
3428
|
+
409: ResourceExistsError,
|
3429
|
+
304: ResourceNotModifiedError,
|
3430
|
+
}
|
3431
|
+
)
|
3419
3432
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3420
3433
|
|
3421
3434
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3440,14 +3453,12 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3440
3453
|
response = pipeline_response.http_response
|
3441
3454
|
|
3442
3455
|
if response.status_code not in [200]:
|
3443
|
-
if _stream:
|
3444
|
-
response.read() # Load the body in memory and close the socket
|
3445
3456
|
map_error(
|
3446
3457
|
status_code=response.status_code, response=response, error_map=error_map
|
3447
3458
|
)
|
3448
3459
|
raise HttpResponseError(response=response)
|
3449
3460
|
|
3450
|
-
deserialized = self._deserialize("object", pipeline_response)
|
3461
|
+
deserialized = self._deserialize("object", pipeline_response.http_response)
|
3451
3462
|
|
3452
3463
|
if cls:
|
3453
3464
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3465,15 +3476,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3465
3476
|
:param job_id: Required.
|
3466
3477
|
:type job_id: int
|
3467
3478
|
:return: dict mapping str to LimitedJobStatusReturn
|
3468
|
-
:rtype: dict[str, ~
|
3479
|
+
:rtype: dict[str, ~generated.models.LimitedJobStatusReturn]
|
3469
3480
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3470
3481
|
"""
|
3471
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3472
|
-
|
3473
|
-
|
3474
|
-
|
3475
|
-
|
3476
|
-
|
3482
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3483
|
+
{ # pylint: disable=unsubscriptable-object
|
3484
|
+
401: ClientAuthenticationError,
|
3485
|
+
404: ResourceNotFoundError,
|
3486
|
+
409: ResourceExistsError,
|
3487
|
+
304: ResourceNotModifiedError,
|
3488
|
+
}
|
3489
|
+
)
|
3477
3490
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3478
3491
|
|
3479
3492
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3500,14 +3513,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3500
3513
|
response = pipeline_response.http_response
|
3501
3514
|
|
3502
3515
|
if response.status_code not in [200]:
|
3503
|
-
if _stream:
|
3504
|
-
response.read() # Load the body in memory and close the socket
|
3505
3516
|
map_error(
|
3506
3517
|
status_code=response.status_code, response=response, error_map=error_map
|
3507
3518
|
)
|
3508
3519
|
raise HttpResponseError(response=response)
|
3509
3520
|
|
3510
|
-
deserialized = self._deserialize(
|
3521
|
+
deserialized = self._deserialize(
|
3522
|
+
"{LimitedJobStatusReturn}", pipeline_response.http_response
|
3523
|
+
)
|
3511
3524
|
|
3512
3525
|
if cls:
|
3513
3526
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3531,14 +3544,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3531
3544
|
:param job_id: Required.
|
3532
3545
|
:type job_id: int
|
3533
3546
|
:param body: Required.
|
3534
|
-
:type body: dict[str, ~
|
3547
|
+
:type body: dict[str, ~generated.models.JobStatusUpdate]
|
3535
3548
|
:keyword force: Default value is False.
|
3536
3549
|
:paramtype force: bool
|
3537
3550
|
:keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
|
3538
3551
|
Default value is "application/json".
|
3539
3552
|
:paramtype content_type: str
|
3540
3553
|
:return: dict mapping str to SetJobStatusReturn
|
3541
|
-
:rtype: dict[str, ~
|
3554
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
3542
3555
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3543
3556
|
"""
|
3544
3557
|
|
@@ -3566,7 +3579,7 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3566
3579
|
Default value is "application/json".
|
3567
3580
|
:paramtype content_type: str
|
3568
3581
|
:return: dict mapping str to SetJobStatusReturn
|
3569
|
-
:rtype: dict[str, ~
|
3582
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
3570
3583
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3571
3584
|
"""
|
3572
3585
|
|
@@ -3586,19 +3599,21 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3586
3599
|
:param job_id: Required.
|
3587
3600
|
:type job_id: int
|
3588
3601
|
:param body: Is either a {str: JobStatusUpdate} type or a IO[bytes] type. Required.
|
3589
|
-
:type body: dict[str, ~
|
3602
|
+
:type body: dict[str, ~generated.models.JobStatusUpdate] or IO[bytes]
|
3590
3603
|
:keyword force: Default value is False.
|
3591
3604
|
:paramtype force: bool
|
3592
3605
|
:return: dict mapping str to SetJobStatusReturn
|
3593
|
-
:rtype: dict[str, ~
|
3606
|
+
:rtype: dict[str, ~generated.models.SetJobStatusReturn]
|
3594
3607
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3595
3608
|
"""
|
3596
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3597
|
-
|
3598
|
-
|
3599
|
-
|
3600
|
-
|
3601
|
-
|
3609
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3610
|
+
{ # pylint: disable=unsubscriptable-object
|
3611
|
+
401: ClientAuthenticationError,
|
3612
|
+
404: ResourceNotFoundError,
|
3613
|
+
409: ResourceExistsError,
|
3614
|
+
304: ResourceNotModifiedError,
|
3615
|
+
}
|
3616
|
+
)
|
3602
3617
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3603
3618
|
|
3604
3619
|
_headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
|
@@ -3638,14 +3653,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3638
3653
|
response = pipeline_response.http_response
|
3639
3654
|
|
3640
3655
|
if response.status_code not in [200]:
|
3641
|
-
if _stream:
|
3642
|
-
response.read() # Load the body in memory and close the socket
|
3643
3656
|
map_error(
|
3644
3657
|
status_code=response.status_code, response=response, error_map=error_map
|
3645
3658
|
)
|
3646
3659
|
raise HttpResponseError(response=response)
|
3647
3660
|
|
3648
|
-
deserialized = self._deserialize(
|
3661
|
+
deserialized = self._deserialize(
|
3662
|
+
"{SetJobStatusReturn}", pipeline_response.http_response
|
3663
|
+
)
|
3649
3664
|
|
3650
3665
|
if cls:
|
3651
3666
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|
@@ -3663,15 +3678,17 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3663
3678
|
:param job_id: Required.
|
3664
3679
|
:type job_id: int
|
3665
3680
|
:return: dict mapping str to list of JobStatusReturn
|
3666
|
-
:rtype: dict[str, list[~
|
3681
|
+
:rtype: dict[str, list[~generated.models.JobStatusReturn]]
|
3667
3682
|
:raises ~azure.core.exceptions.HttpResponseError:
|
3668
3683
|
"""
|
3669
|
-
error_map: MutableMapping[int, Type[HttpResponseError]] =
|
3670
|
-
|
3671
|
-
|
3672
|
-
|
3673
|
-
|
3674
|
-
|
3684
|
+
error_map: MutableMapping[int, Type[HttpResponseError]] = (
|
3685
|
+
{ # pylint: disable=unsubscriptable-object
|
3686
|
+
401: ClientAuthenticationError,
|
3687
|
+
404: ResourceNotFoundError,
|
3688
|
+
409: ResourceExistsError,
|
3689
|
+
304: ResourceNotModifiedError,
|
3690
|
+
}
|
3691
|
+
)
|
3675
3692
|
error_map.update(kwargs.pop("error_map", {}) or {})
|
3676
3693
|
|
3677
3694
|
_headers = kwargs.pop("headers", {}) or {}
|
@@ -3696,14 +3713,14 @@ class JobsOperations: # pylint: disable=too-many-public-methods
|
|
3696
3713
|
response = pipeline_response.http_response
|
3697
3714
|
|
3698
3715
|
if response.status_code not in [200]:
|
3699
|
-
if _stream:
|
3700
|
-
response.read() # Load the body in memory and close the socket
|
3701
3716
|
map_error(
|
3702
3717
|
status_code=response.status_code, response=response, error_map=error_map
|
3703
3718
|
)
|
3704
3719
|
raise HttpResponseError(response=response)
|
3705
3720
|
|
3706
|
-
deserialized = self._deserialize(
|
3721
|
+
deserialized = self._deserialize(
|
3722
|
+
"{[JobStatusReturn]}", pipeline_response.http_response
|
3723
|
+
)
|
3707
3724
|
|
3708
3725
|
if cls:
|
3709
3726
|
return cls(pipeline_response, deserialized, {}) # type: ignore
|