rapida-python 0.0.4__py3-none-any.whl → 0.0.5__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.
- rapida/exceptions/exceptions.py +13 -4
- rapida/rapida_client.py +0 -3
- rapida/rapida_client_options.py +2 -2
- rapida/version.py +1 -1
- {rapida_python-0.0.4.dist-info → rapida_python-0.0.5.dist-info}/METADATA +1 -1
- {rapida_python-0.0.4.dist-info → rapida_python-0.0.5.dist-info}/RECORD +8 -8
- {rapida_python-0.0.4.dist-info → rapida_python-0.0.5.dist-info}/WHEEL +0 -0
- {rapida_python-0.0.4.dist-info → rapida_python-0.0.5.dist-info}/top_level.txt +0 -0
rapida/exceptions/exceptions.py
CHANGED
|
@@ -44,19 +44,22 @@ class RapidaConfigurationException(RapidaException):
|
|
|
44
44
|
An error caused by client or server configuration
|
|
45
45
|
"""
|
|
46
46
|
|
|
47
|
-
|
|
47
|
+
def __init__(self, message: str, source: str):
|
|
48
|
+
super().__init__(400, message, source)
|
|
48
49
|
|
|
49
50
|
|
|
50
51
|
class RapidaInternalServerException(RapidaException):
|
|
51
52
|
"""An error caused by uncontrolled server response"""
|
|
52
53
|
|
|
53
|
-
|
|
54
|
+
def __init__(self, code: int, message: str, source: str):
|
|
55
|
+
super().__init__(code, message, source)
|
|
54
56
|
|
|
55
57
|
|
|
56
58
|
class RapidaInvalidAPIException(RapidaException):
|
|
57
59
|
"""Raised if the provider API key is invalid."""
|
|
58
60
|
|
|
59
|
-
|
|
61
|
+
def __init__(self, code: int, message: str, source: str):
|
|
62
|
+
super().__init__(code, message, source)
|
|
60
63
|
|
|
61
64
|
|
|
62
65
|
def handle_request_exception(error: InvokerError):
|
|
@@ -84,8 +87,14 @@ def handle_request_exception(error: InvokerError):
|
|
|
84
87
|
|
|
85
88
|
|
|
86
89
|
class RapidaWarning(Warning):
|
|
90
|
+
"""
|
|
91
|
+
Warning message
|
|
92
|
+
"""
|
|
93
|
+
|
|
94
|
+
message: str
|
|
95
|
+
|
|
87
96
|
def __init__(self, message: str):
|
|
88
|
-
super().__init__(
|
|
97
|
+
super().__init__(message)
|
|
89
98
|
|
|
90
99
|
def __str__(self) -> str:
|
|
91
100
|
"""
|
rapida/rapida_client.py
CHANGED
|
@@ -30,9 +30,6 @@ class RapidaClient:
|
|
|
30
30
|
if options.rapida_api_key is None or len(options.rapida_api_key) == 0:
|
|
31
31
|
raise RapidaConfigurationException("The provided API key is invalid.")
|
|
32
32
|
|
|
33
|
-
if options.rapida_endpoint_url is None or len(options.rapida_endpoint_url) == 0:
|
|
34
|
-
raise RapidaConfigurationException("The provided endpoint URL is invalid.")
|
|
35
|
-
|
|
36
33
|
self.options = options
|
|
37
34
|
self.rapida_bridge = RapidaBridge(
|
|
38
35
|
service_url=options.rapida_endpoint_url,
|
rapida/rapida_client_options.py
CHANGED
|
@@ -85,8 +85,8 @@ class RapidaClientOptions:
|
|
|
85
85
|
environment:
|
|
86
86
|
"""
|
|
87
87
|
self.rapida_api_key = api_key or os.environ.get("RAPIDA_API_KEY")
|
|
88
|
-
self.rapida_endpoint_url =
|
|
89
|
-
"RAPIDA_ENDPOINT_URL" or self.ENDPOINT_URL
|
|
88
|
+
self.rapida_endpoint_url = (
|
|
89
|
+
endpoint_url or os.environ.get("RAPIDA_ENDPOINT_URL") or self.ENDPOINT_URL
|
|
90
90
|
)
|
|
91
91
|
self.rapida_environment = environment or os.environ.get("RAPIDA_ENVIRONMENT")
|
|
92
92
|
self.rapida_region = region or os.environ.get("RAPIDA_REGION")
|
rapida/version.py
CHANGED
|
@@ -3,10 +3,10 @@ rapida/client.py,sha256=MVMKMg0toPNA0AUlJNFad61nSbfu8zTeQsSkq5Z2-Q4,803
|
|
|
3
3
|
rapida/exceptions.py,sha256=zQgIbRlYEzMI8-5mx7KI9NSeP6FF75UQ4--o0xZjP_o,1778
|
|
4
4
|
rapida/http_client.py,sha256=_L0Ioep0bBavNGQ6m2kuXh4V98eqqGNvOSMJt0CN50o,1045
|
|
5
5
|
rapida/options.py,sha256=85AOqWLEFd4-Wxr29OI5b59RYb1-Uyb-YcMzx8IbQC8,463
|
|
6
|
-
rapida/rapida_client.py,sha256=
|
|
7
|
-
rapida/rapida_client_options.py,sha256=
|
|
6
|
+
rapida/rapida_client.py,sha256=erlDXJQUT6gVLLl3VKspisMkdxpDIqyTIKXP1IezHYg,5148
|
|
7
|
+
rapida/rapida_client_options.py,sha256=P_54uLDqVJnnMITDdNMEaNRjMghmVKgffT1bOQTpcz0,2382
|
|
8
8
|
rapida/util.py,sha256=qB0PX71MTglzp5J3AGIY7F4-ReWBuxSQdRsh-5Kuezw,1418
|
|
9
|
-
rapida/version.py,sha256=
|
|
9
|
+
rapida/version.py,sha256=HBduVYNOHnd6dXMNT8zPaxMdMM6zwlY01CBBUveLmVI,159
|
|
10
10
|
rapida/api_resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
11
|
rapida/api_resources/deployments.py,sha256=HbsY4RUDXAgJKlQDtpUwmNk1Z0RXB8qMW0QO6Z_F0jM,16590
|
|
12
12
|
rapida/artifacts/__init__.py,sha256=uunvHyOaVic6mTNNF4PCIyo1VGRDH5PwAoLhf3I-lCA,35
|
|
@@ -20,10 +20,10 @@ rapida/client/grpc_bridge.py,sha256=NX7uVViaOVeAzE0K0lduJJ5Zj3lTskCVo887KFjOeFs,
|
|
|
20
20
|
rapida/client/rapida_bridge.py,sha256=SxoWHq5oriWZBQidzOy7rmJT8OXCNLL8C5yqxAlNk3o,3767
|
|
21
21
|
rapida/client/response_wrapper.py,sha256=6Gy9bE7Yi5a3wFbwyVhbDZuBJHhD5wfYi4E9F5qzX5c,2417
|
|
22
22
|
rapida/exceptions/__init__.py,sha256=2wuqt5z5AWGqMJtR0ba_GQ0irANPOTR7AYakT-vbZwY,400
|
|
23
|
-
rapida/exceptions/exceptions.py,sha256=
|
|
23
|
+
rapida/exceptions/exceptions.py,sha256=KAuQpDaVhOUfGcX2FpZdmgob691GmPMAT3KK2TaN8dA,2847
|
|
24
24
|
rapida/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
25
25
|
rapida/tests/test_deployments.py,sha256=zgr0PTPoLqzKkSudR3lmzj1lUAkNiAPsWx42aKG-SAQ,36
|
|
26
|
-
rapida_python-0.0.
|
|
27
|
-
rapida_python-0.0.
|
|
28
|
-
rapida_python-0.0.
|
|
29
|
-
rapida_python-0.0.
|
|
26
|
+
rapida_python-0.0.5.dist-info/METADATA,sha256=Vwc2PNcfz69XcJGvzQKDfSUjeCarRj3KO5EvM_kCti4,2321
|
|
27
|
+
rapida_python-0.0.5.dist-info/WHEEL,sha256=yQN5g4mg4AybRjkgi-9yy4iQEFibGQmlz78Pik5Or-A,92
|
|
28
|
+
rapida_python-0.0.5.dist-info/top_level.txt,sha256=1OJt64VrZ3n2N8GBqlUSoQ3qvPv30QBYD--xOZv3R2g,7
|
|
29
|
+
rapida_python-0.0.5.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|