naeural-client 2.6.36__py3-none-any.whl → 2.6.37__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.
naeural_client/_ver.py CHANGED
@@ -1,4 +1,4 @@
1
- __VER__ = "2.6.36"
1
+ __VER__ = "2.6.37"
2
2
 
3
3
  if __name__ == "__main__":
4
4
  with open("pyproject.toml", "rt") as fd:
naeural_client/bc/base.py CHANGED
@@ -947,8 +947,29 @@ class BaseBlockEngine:
947
947
  True if the current address is in the list.
948
948
 
949
949
  """
950
+ return self.address_in_list(self.address, lst_addresses)
951
+
952
+ def address_in_list(self, node_address, lst_addresses):
953
+ """
954
+ Checks if the address is in the list of addresses
955
+
956
+ Parameters
957
+ ----------
958
+ node_address : str
959
+ the address.
960
+
961
+ lst_addresses : list
962
+ the list of addresses.
963
+
964
+ Returns
965
+ -------
966
+ bool
967
+ True if the address is in the list.
968
+
969
+ """
970
+ node_address = self._remove_prefix(node_address)
950
971
  lst = [self._remove_prefix(x) for x in lst_addresses if x is not None]
951
- return self.address_no_prefix in lst
972
+ return node_address in lst
952
973
 
953
974
  @property
954
975
  def address(self):
@@ -977,6 +998,14 @@ class BaseBlockEngine:
977
998
  Returns a tuple with the allowed list (prefixed) and a list with names
978
999
  """
979
1000
  return self._load_and_maybe_create_allowed(return_names=True, return_prefix=True)
1001
+
1002
+
1003
+ @property
1004
+ def whitelist_with_prefixes(self):
1005
+ """
1006
+ Returns the allowed command senders (prefixed) for the current node
1007
+ """
1008
+ return self._load_and_maybe_create_allowed(return_names=False, return_prefix=True)
980
1009
 
981
1010
 
982
1011
  def maybe_remove_prefix(self, address):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: naeural_client
3
- Version: 2.6.36
3
+ Version: 2.6.37
4
4
  Summary: `naeural_client` is the Python SDK required for client app development for the Naeural Edge Protocol Edge Protocol framework
5
5
  Project-URL: Homepage, https://github.com/NaeuralEdgeProtocol/naeural_client
6
6
  Project-URL: Bug Tracker, https://github.com/NaeuralEdgeProtocol/naeural_client/issues
@@ -1,5 +1,5 @@
1
1
  naeural_client/__init__.py,sha256=YimqgDbjLuywsf8zCWE0EaUXH4MBUrqLxt0TDV558hQ,632
2
- naeural_client/_ver.py,sha256=6t-SwzxKBggn_iUUZf0CxWwcdfnYtoGoUiaW3TiSHDE,331
2
+ naeural_client/_ver.py,sha256=Kz07pCrAEvKbAHrCINS6PyoSTVp83A2pwXAu8UB_eUc,331
3
3
  naeural_client/base_decentra_object.py,sha256=C4iwZTkhKNBS4VHlJs5DfElRYLo4Q9l1V1DNVSk1fyQ,4412
4
4
  naeural_client/plugins_manager_mixin.py,sha256=X1JdGLDz0gN1rPnTN_5mJXR8JmqoBFQISJXmPR9yvCo,11106
5
5
  naeural_client/base/__init__.py,sha256=hACh83_cIv7-PwYMM3bQm2IBmNqiHw-3PAfDfAEKz9A,259
@@ -14,7 +14,7 @@ naeural_client/base/webapp_pipeline.py,sha256=ZNGqZ36DY076XVDfGu2Q61kCt3kxIJ4Mi4
14
14
  naeural_client/base/payload/__init__.py,sha256=y8fBI8tG2ObNfaXFWjyWZXwu878FRYj_I8GIbHT4GKE,29
15
15
  naeural_client/base/payload/payload.py,sha256=x-au7l67Z_vfn_4R2C_pjZCaFuUVXHngJiGOfIAYVdE,2690
16
16
  naeural_client/bc/__init__.py,sha256=FQj23D1PrY06NUOARiKQi4cdj0-VxnoYgYDEht8lpr8,158
17
- naeural_client/bc/base.py,sha256=kvPRvjKyFjjwa3GZF6BYbcITwoAfjtc0k0DP0FXpfgw,42274
17
+ naeural_client/bc/base.py,sha256=64hbp866n2DBCc7xxzEniszr4dQ-0rLKJPKIQsST0Ig,42950
18
18
  naeural_client/bc/chain.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
19
19
  naeural_client/bc/ec.py,sha256=qI8l7YqiS4MNftlx-tF7IZUswrSeQc7KMn5OZ0fEaJs,23370
20
20
  naeural_client/certs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -83,8 +83,8 @@ naeural_client/utils/comm_utils.py,sha256=4cS9llRr_pK_3rNgDcRMCQwYPO0kcNU7AdWy_L
83
83
  naeural_client/utils/config.py,sha256=Ub5sw3NG6wskAF5C4s0WU0rzXHVLy70ZTRU0W8HUGTM,6403
84
84
  naeural_client/utils/dotenv.py,sha256=_AgSo35n7EnQv5yDyu7C7i0kHragLJoCGydHjvOkrYY,2008
85
85
  naeural_client/utils/oracle_sync/multiple_requests.py,sha256=GLzROGZ0gI4d1PVWgW_JBUYZjEL4LqZvHvwelxDiPW4,20892
86
- naeural_client-2.6.36.dist-info/METADATA,sha256=agTn5JHFNaEb7pzOfgVN9sHfJC_sjFuqhjgYGfeZuGo,12354
87
- naeural_client-2.6.36.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
88
- naeural_client-2.6.36.dist-info/entry_points.txt,sha256=CTua17GUrRa4aXeafezGC9TiWKGKQzwTjQmB2jyj22g,91
89
- naeural_client-2.6.36.dist-info/licenses/LICENSE,sha256=cvOsJVslde4oIaTCadabXnPqZmzcBO2f2zwXZRmJEbE,11311
90
- naeural_client-2.6.36.dist-info/RECORD,,
86
+ naeural_client-2.6.37.dist-info/METADATA,sha256=geNzXBl8TAuOA9uhBLfAd5nk_YH0aa_BWfX0hX--INs,12354
87
+ naeural_client-2.6.37.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
88
+ naeural_client-2.6.37.dist-info/entry_points.txt,sha256=CTua17GUrRa4aXeafezGC9TiWKGKQzwTjQmB2jyj22g,91
89
+ naeural_client-2.6.37.dist-info/licenses/LICENSE,sha256=cvOsJVslde4oIaTCadabXnPqZmzcBO2f2zwXZRmJEbE,11311
90
+ naeural_client-2.6.37.dist-info/RECORD,,