zepben.ewb 1.0.0b5__py3-none-any.whl → 1.0.0b7__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.
- zepben/ewb/streaming/grpc/grpc_channel_builder.py +6 -1
- {zepben_ewb-1.0.0b5.dist-info → zepben_ewb-1.0.0b7.dist-info}/METADATA +13 -24
- {zepben_ewb-1.0.0b5.dist-info → zepben_ewb-1.0.0b7.dist-info}/RECORD +6 -6
- {zepben_ewb-1.0.0b5.dist-info → zepben_ewb-1.0.0b7.dist-info}/WHEEL +0 -0
- {zepben_ewb-1.0.0b5.dist-info → zepben_ewb-1.0.0b7.dist-info}/licenses/LICENSE +0 -0
- {zepben_ewb-1.0.0b5.dist-info → zepben_ewb-1.0.0b7.dist-info}/top_level.txt +0 -0
|
@@ -86,6 +86,7 @@ class GrpcChannelBuilder(ABC):
|
|
|
86
86
|
|
|
87
87
|
def _test_connection(self, channel: grpc.Channel, debug: bool, timeout_seconds: int):
|
|
88
88
|
debug_errors = []
|
|
89
|
+
permission_errors = []
|
|
89
90
|
for name, client in zip(self._stubs.keys(), map(lambda stub: stub(channel), list(self._stubs.values()))):
|
|
90
91
|
try:
|
|
91
92
|
result = client.checkConnection(CheckConnectionRequest(), timeout=timeout_seconds, wait_for_ready=False)
|
|
@@ -93,7 +94,11 @@ class GrpcChannelBuilder(ABC):
|
|
|
93
94
|
return
|
|
94
95
|
except _InactiveRpcError as rpc_error:
|
|
95
96
|
debug_errors.append(f"Received the following exception with {name}:\n{rpc_error}\n")
|
|
96
|
-
|
|
97
|
+
if rpc_error.code() in (grpc.StatusCode.UNAUTHENTICATED, grpc.StatusCode.PERMISSION_DENIED):
|
|
98
|
+
permission_errors.append(f"Received the following exception with {name}:\n\t{rpc_error.code().name}: {rpc_error.details()}\n")
|
|
99
|
+
# Preference propagating permissions errors to users if any exist, otherwise just take the first error from the first service we tried.
|
|
100
|
+
propagate = ''.join(permission_errors) if permission_errors else debug_errors[0]
|
|
101
|
+
raise GrpcConnectionException(f"Couldn't establish gRPC connection to any service on {self._socket_address}.\n{''.join(debug_errors) if debug else propagate}")
|
|
97
102
|
|
|
98
103
|
def for_address(self, host: str, port: int) -> 'GrpcChannelBuilder':
|
|
99
104
|
"""
|
|
@@ -1,49 +1,38 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: zepben.ewb
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.0b7
|
|
4
4
|
Summary: Python SDK for interacting with the Energy Workbench platform
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
Classifier: License :: OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)
|
|
5
|
+
Author-email: Kurt Greaves <kurt.greaves@zepben.com>, Max Chesterfield <max.chesterfield@zepben.com>
|
|
6
|
+
License-Expression: MPL-2.0
|
|
7
|
+
Project-URL: Repository, https://github.com/zepben/evolve-sdk-python
|
|
8
|
+
Project-URL: Homepage, https://zepben.com
|
|
10
9
|
Classifier: Programming Language :: Python :: 3
|
|
11
10
|
Classifier: Programming Language :: Python :: 3.9
|
|
12
11
|
Classifier: Programming Language :: Python :: 3.10
|
|
13
12
|
Classifier: Programming Language :: Python :: 3.11
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
14
14
|
Classifier: Operating System :: OS Independent
|
|
15
|
-
Requires-Python:
|
|
15
|
+
Requires-Python: <3.13,>=3.9
|
|
16
16
|
Description-Content-Type: text/markdown
|
|
17
17
|
License-File: LICENSE
|
|
18
|
-
Requires-Dist: zepben
|
|
18
|
+
Requires-Dist: zepben.protobuf==1.0.0b1
|
|
19
19
|
Requires-Dist: typing_extensions==4.12.2
|
|
20
20
|
Requires-Dist: requests<3.0.0,>=2.26.0
|
|
21
21
|
Requires-Dist: urllib3<1.27.0,>=1.26.6
|
|
22
22
|
Requires-Dist: PyJWT<2.2.0,>=2.1.0
|
|
23
23
|
Requires-Dist: dataclassy==0.6.2
|
|
24
24
|
Provides-Extra: test
|
|
25
|
-
Requires-Dist: pytest
|
|
26
|
-
Requires-Dist: pytest-cov==
|
|
27
|
-
Requires-Dist: pytest-asyncio==0.
|
|
28
|
-
Requires-Dist: pytest-timeout==
|
|
25
|
+
Requires-Dist: pytest<9,>=7.4.4; extra == "test"
|
|
26
|
+
Requires-Dist: pytest-cov==6.1.1; extra == "test"
|
|
27
|
+
Requires-Dist: pytest-asyncio==0.26.0; extra == "test"
|
|
28
|
+
Requires-Dist: pytest-timeout==2.4.0; extra == "test"
|
|
29
29
|
Requires-Dist: pytest-subtests; extra == "test"
|
|
30
|
-
Requires-Dist: hypothesis==6.
|
|
30
|
+
Requires-Dist: hypothesis==6.119.4; extra == "test"
|
|
31
31
|
Requires-Dist: grpcio-testing==1.61.3; extra == "test"
|
|
32
32
|
Requires-Dist: pylint==2.14.5; extra == "test"
|
|
33
33
|
Requires-Dist: six==1.16.0; extra == "test"
|
|
34
34
|
Requires-Dist: tox; extra == "test"
|
|
35
|
-
Dynamic: author
|
|
36
|
-
Dynamic: author-email
|
|
37
|
-
Dynamic: classifier
|
|
38
|
-
Dynamic: description
|
|
39
|
-
Dynamic: description-content-type
|
|
40
|
-
Dynamic: home-page
|
|
41
|
-
Dynamic: license
|
|
42
35
|
Dynamic: license-file
|
|
43
|
-
Dynamic: provides-extra
|
|
44
|
-
Dynamic: requires-dist
|
|
45
|
-
Dynamic: requires-python
|
|
46
|
-
Dynamic: summary
|
|
47
36
|
|
|
48
37
|

|
|
49
38
|
[](https://codecov.io/gh/zepben/evolve-sdk-python)
|
|
@@ -628,14 +628,14 @@ zepben/ewb/streaming/grpc/__init__.py,sha256=waADXEvfUG9wAN4STx5uIUHOv0UnpZLH2qU
|
|
|
628
628
|
zepben/ewb/streaming/grpc/auth_token_plugin.py,sha256=zg3UJF9qJ_Ov7Pczjhd4B_-BKaAr35JlAFLLdm1jg7U,804
|
|
629
629
|
zepben/ewb/streaming/grpc/connect.py,sha256=xRifzFzlbVuEoRY79fasGO-E-zLtGpGKUF5F9CusI6g,10504
|
|
630
630
|
zepben/ewb/streaming/grpc/grpc.py,sha256=q2tncPR9jMfcOB71R5mnJi1ZVp7F3X1-NIUhf0Zw2jA,3824
|
|
631
|
-
zepben/ewb/streaming/grpc/grpc_channel_builder.py,sha256
|
|
631
|
+
zepben/ewb/streaming/grpc/grpc_channel_builder.py,sha256=k2v1zkDeDgYdc2kqdBsntEeQWHm8qqt1L62UTxnNDqw,9225
|
|
632
632
|
zepben/ewb/streaming/mutations/__init__.py,sha256=waADXEvfUG9wAN4STx5uIUHOv0UnpZLH2qU1LXgaDBc,243
|
|
633
633
|
zepben/ewb/streaming/mutations/update_network_state_client.py,sha256=e0Oma5PRT8mW7EQs-zGVIQYpT-LxAz-mQ579LBevW-c,3922
|
|
634
634
|
zepben/ewb/streaming/mutations/update_network_state_service.py,sha256=irR-TO67QXRyBmK8PU8SzM31NKSSefZt_nQGHi5IhT8,3260
|
|
635
635
|
zepben/ewb/testing/__init__.py,sha256=waADXEvfUG9wAN4STx5uIUHOv0UnpZLH2qU1LXgaDBc,243
|
|
636
636
|
zepben/ewb/testing/test_network_builder.py,sha256=KG0o2ZHUswx3xClu-JnLs_pYIYbQ5jjtvtyZ7LI6IZ8,38092
|
|
637
|
-
zepben_ewb-1.0.
|
|
638
|
-
zepben_ewb-1.0.
|
|
639
|
-
zepben_ewb-1.0.
|
|
640
|
-
zepben_ewb-1.0.
|
|
641
|
-
zepben_ewb-1.0.
|
|
637
|
+
zepben_ewb-1.0.0b7.dist-info/licenses/LICENSE,sha256=aAHD66h6PQIETpkJDvg5yEObyFvXUED8u7S8dlh6K0Y,16725
|
|
638
|
+
zepben_ewb-1.0.0b7.dist-info/METADATA,sha256=3STVNHTFz_Fii6k50mCE5WKGNcqr_eTfERhKAL8J8vQ,3300
|
|
639
|
+
zepben_ewb-1.0.0b7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
640
|
+
zepben_ewb-1.0.0b7.dist-info/top_level.txt,sha256=eVLDJiO6FGjL_Z7KdmFE-R8uf1Q07aaVLGe9Ee4kmBw,7
|
|
641
|
+
zepben_ewb-1.0.0b7.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|