motorcortex-python 0.22.3__tar.gz → 0.22.5__tar.gz

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.
Files changed (36) hide show
  1. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/PKG-INFO +1 -1
  2. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/request.py +1 -1
  3. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/subscribe.py +1 -1
  4. motorcortex-python-0.22.5/motorcortex/version.py +1 -0
  5. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex_python.egg-info/PKG-INFO +1 -1
  6. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex_python.egg-info/SOURCES.txt +0 -1
  7. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/sandbox/req_test.py +2 -2
  8. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/api_test.py +10 -10
  9. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/async_test.py +1 -1
  10. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/nng_tls_client.py +1 -1
  11. motorcortex-python-0.22.3/motorcortex/version.py +0 -1
  12. motorcortex-python-0.22.3/test/mcx.cert.pem +0 -27
  13. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/.gitignore +0 -0
  14. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/LICENSE +0 -0
  15. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/MANIFEST.in +0 -0
  16. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/PIPHOWTO.md +0 -0
  17. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/README.md +0 -0
  18. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/__init__.py +0 -0
  19. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/message_types.py +0 -0
  20. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/motorcortex_hash.json +0 -0
  21. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/motorcortex_pb2.py +0 -0
  22. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/parameter_tree.py +0 -0
  23. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/reply.py +0 -0
  24. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/setup_logger.py +0 -0
  25. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex/subscription.py +0 -0
  26. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex_python.egg-info/dependency_links.txt +0 -0
  27. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex_python.egg-info/requires.txt +0 -0
  28. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/motorcortex_python.egg-info/top_level.txt +0 -0
  29. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/pydoc-markdown.yml +0 -0
  30. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/sandbox/test.crt +0 -0
  31. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/setup.cfg +0 -0
  32. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/setup.py +0 -0
  33. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/motorcortex-msg/motionSL_hash.json +0 -0
  34. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/motorcortex-msg/motionSL_pb2.py +0 -0
  35. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/motorcortex-msg/motorcortex_hash.json +0 -0
  36. {motorcortex-python-0.22.3 → motorcortex-python-0.22.5}/test/motorcortex-msg/motorcortex_pb2.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: motorcortex-python
3
- Version: 0.22.3
3
+ Version: 0.22.5
4
4
  Summary: Python bindings for Motorcortex Engine
5
5
  Home-page: https://www.motorcortex.io
6
6
  Author: Alexey Zakharov
@@ -93,7 +93,7 @@ class Request(object):
93
93
 
94
94
  self.__socket.add_post_pipe_connect_cb(pre_connect_cb)
95
95
  self.__socket.add_post_pipe_remove_cb(post_remove_cb)
96
- self.__socket.dial(url)
96
+ self.__socket.dial(url, block=False)
97
97
 
98
98
  return Reply(self.__pool.submit(self.waitForConnection, self.__connected_lock,
99
99
  conn_timeout_ms / 1000.0))
@@ -77,7 +77,7 @@ class Subscribe:
77
77
 
78
78
  self.__socket.add_pre_pipe_connect_cb(pre_connect_cb)
79
79
  self.__socket.add_post_pipe_remove_cb(post_remove_cb)
80
- self.__socket.dial(url)
80
+ self.__socket.dial(url, block=False)
81
81
 
82
82
  self.__pool.submit(self.run, self.__socket)
83
83
 
@@ -0,0 +1 @@
1
+ __version__ = '0.22.5'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: motorcortex-python
3
- Version: 0.22.3
3
+ Version: 0.22.5
4
4
  Summary: Python bindings for Motorcortex Engine
5
5
  Home-page: https://www.motorcortex.io
6
6
  Author: Alexey Zakharov
@@ -25,7 +25,6 @@ sandbox/req_test.py
25
25
  sandbox/test.crt
26
26
  test/api_test.py
27
27
  test/async_test.py
28
- test/mcx.cert.pem
29
28
  test/nng_tls_client.py
30
29
  test/motorcortex-msg/motionSL_hash.json
31
30
  test/motorcortex-msg/motionSL_pb2.py
@@ -9,14 +9,14 @@ if __name__ == '__main__':
9
9
  # Vectioneer camera
10
10
  endpoint_1 = "ws://motorcortex:5558:5557"
11
11
  req, sub = motorcortex.connect(endpoint_1, motorcortex_types, parameter_tree,
12
- certificate="mcx.cert.pem", timeout_ms=1000,
12
+ certificate="mcx.cert.crt", timeout_ms=1000,
13
13
  login="", password="")
14
14
 
15
15
 
16
16
  # Local processing
17
17
  endpoint_2 = "wss://localhost:5568:5567"
18
18
  req1, sub1 = motorcortex.connect(endpoint_2, motorcortex.MessageTypes(), motorcortex.ParameterTree(),
19
- certificate="mcx.cert.pem", timeout_ms=1000,
19
+ certificate="mcx.cert.crt", timeout_ms=1000,
20
20
  login="", password="")
21
21
 
22
22
  print("Sending data from {} to {}".format(endpoint_1, endpoint_2))
@@ -111,7 +111,7 @@ class Reconnection(unittest.TestCase):
111
111
 
112
112
  # Open request connection
113
113
  req, sub = motorcortex.connect("wss://127.0.0.1:5568:5567", motorcortex_types, parameter_tree,
114
- certificate="mcx.cert.pem", timeout_ms=5000,
114
+ certificate="mcx.cert.crt", timeout_ms=5000,
115
115
  login="root", password="vectioneer")
116
116
 
117
117
  sub.subscribe(["root/Comm_task/actual_cycle_max"], "test", 2000).notify(lambda x: print(f"1:{x}"))
@@ -235,7 +235,7 @@ class ParameterTree(unittest.TestCase):
235
235
  # logging.basicConfig(level=logging.INFO)
236
236
  # Open request connection
237
237
  req, sub = motorcortex.connect("wss://localhost:5568:5567", motorcortex_types, parameter_tree,
238
- certificate="mcx.cert.pem", timeout_ms=1000, login="", password="")
238
+ certificate="mcx.cert.crt", timeout_ms=1000, login="", password="")
239
239
 
240
240
  path = tempfile.gettempdir() + '/' + 'mcx-python-ParameterTree-hash'
241
241
  tree = req.getParameterTree().get()
@@ -312,7 +312,7 @@ class OverwriteReleaseParameter(unittest.TestCase):
312
312
 
313
313
  # Open request connection
314
314
  req, sub = motorcortex.connect("wss://127.0.0.1:5568:5567", motorcortex_types, parameter_tree,
315
- certificate="mcx.cert.pem", timeout_ms=5000,
315
+ certificate="mcx.cert.crt", timeout_ms=5000,
316
316
  login="root", password="vectioneer")
317
317
 
318
318
  ## test non-existing path
@@ -383,7 +383,7 @@ class StreamTest(unittest.TestCase):
383
383
 
384
384
  # Open request connection
385
385
  req, sub = motorcortex.connect("ws://localhost:5558:5557", motorcortex_types, parameter_tree,
386
- certificate="mcx.cert.pem", timeout_ms=5000,
386
+ certificate="mcx.cert.crt", timeout_ms=5000,
387
387
  login="", password="")
388
388
 
389
389
  subscription = sub.subscribe(["root/Comm_task/utilization_max",
@@ -426,7 +426,7 @@ class ConnectionTimeout(unittest.TestCase):
426
426
 
427
427
  # Open request connection
428
428
  req, sub = motorcortex.connect("wss://localhost:5568:5567", motorcortex_types, parameter_tree,
429
- certificate="mcx.cert.pem", timeout_ms=5000,
429
+ certificate="mcx.cert.crt", timeout_ms=5000,
430
430
  login="test", password="test", state_update=self.stateChange)
431
431
 
432
432
  while True:
@@ -449,7 +449,7 @@ class GetParameter(unittest.TestCase):
449
449
 
450
450
  # Open request connection
451
451
  req, sub = motorcortex.connect("wss://192.168.179.85:5568:5567", motorcortex_types, parameter_tree,
452
- certificate="mcx.cert.pem", timeout_ms=5000,
452
+ certificate="mcx.cert.crt", timeout_ms=5000,
453
453
  login="test", password="test")
454
454
 
455
455
  rep = req.getParameterList(["root/Logic/mode",
@@ -474,7 +474,7 @@ class SubParameter(unittest.TestCase):
474
474
 
475
475
  parameter_tree = motorcortex.ParameterTree()
476
476
  req = motorcortex.Request(motorcortex_types, parameter_tree)
477
- if req.connect("wss://%s:5568" % SERVER, certificate="mcx.cert.pem").get(5000):
477
+ if req.connect("wss://%s:5568" % SERVER, certificate="mcx.cert.crt").get(5000):
478
478
  print("Request connection is etablished")
479
479
  else:
480
480
  print("Failed to establish Request connection")
@@ -499,7 +499,7 @@ class SubParameter(unittest.TestCase):
499
499
  self.assertTrue(False)
500
500
 
501
501
  sub = motorcortex.Subscribe(req, motorcortex_types)
502
- if sub.connect("wss://%s:5567" % SERVER, certificate="mcx.cert.pem").get(1000):
502
+ if sub.connect("wss://%s:5567" % SERVER, certificate="mcx.cert.crt").get(1000):
503
503
  print("Subscribe connection is etablished")
504
504
  else:
505
505
  print("Failed to establish Subscribe connection")
@@ -531,7 +531,7 @@ class SetString(unittest.TestCase):
531
531
  parameter_tree = motorcortex.ParameterTree()
532
532
  # Open request and subscribe connection
533
533
  req, sub = motorcortex.connect("wss://localhost:5568:5567", motorcortex.MessageTypes(), parameter_tree,
534
- certificate="mcx.cert.pem", timeout_ms=1000,
534
+ certificate="mcx.cert.crt", timeout_ms=1000,
535
535
  login="root", password="secret")
536
536
  res = req.setParameter("root/Control/dummyChar", "Hallo robot!")
537
537
  res.get()
@@ -542,7 +542,7 @@ class SetParameterWithOffset(unittest.TestCase):
542
542
  parameter_tree = motorcortex.ParameterTree()
543
543
  # Open request and subscribe connection
544
544
  req, sub = motorcortex.connect("wss://localhost:5568:5567", motorcortex.MessageTypes(), parameter_tree,
545
- certificate="mcx.cert.pem", timeout_ms=1000,
545
+ certificate="mcx.cert.crt", timeout_ms=1000,
546
546
  login="root", password="secret")
547
547
  res = req.setParameter("root/Control/hostInJointTrajectory", [6, 5])
548
548
  res.get()
@@ -30,7 +30,7 @@ def main(id):
30
30
 
31
31
  # Open request connection
32
32
  req, sub = motorcortex.connect("wss://192.168.2.100:5568:5567", motorcortex_types, parameter_tree,
33
- certificate="mcx.cert.pem", timeout_ms=1000,
33
+ certificate="mcx.cert.crt", timeout_ms=1000,
34
34
  login="", password="")
35
35
 
36
36
  start = time.time()
@@ -25,7 +25,7 @@ if __name__ == '__main__':
25
25
 
26
26
  threads = []
27
27
  for i in range(50):
28
- threads.append(threading.Thread(target=test, args=(i, 'wss://localhost:5555', 'mcx.cert.pem')))
28
+ threads.append(threading.Thread(target=test, args=(i, 'wss://localhost:5555', 'mcx.cert.crt')))
29
29
  threads[-1].start()
30
30
  time.sleep(0.01)
31
31
 
@@ -1 +0,0 @@
1
- __version__ = '0.22.3'
@@ -1,27 +0,0 @@
1
- -----BEGIN CERTIFICATE-----
2
- MIIEkDCCA3igAwIBAgITbTjd78AWwnYgjliiB1pdOZrHuzANBgkqhkiG9w0BAQsF
3
- ADCBzzELMAkGA1UEBhMCTkwxEDAOBgNVBAgMB0xpbWJ1cmcxKzApBgNVBAcMIkth
4
- cnZlZWx3ZWcgMTlCLCA2MjIyIE5KIE1hYXN0cmljaHQxKTAnBgNVBAoMIFZlY3Rp
5
- b25lZXIgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MRQwEgYDVQQ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