test: gevent thread exception is back
The gevent cannot switch to a different thread
for Redis connections is back
https://gitlab.esrf.fr/bliss/bliss/-/jobs/154638
_________________________ test_reapplying_ctrl_params __________________________
default_session = <bliss.common.session.DefaultSession object at 0x7f532fbd9710>
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f533c96d950>
def test_reapplying_ctrl_params(default_session, caplog):
simulator = default_session.config.get("lima_simulator")
with lima_simulator_context("simulator", "id00/limaccds/simulator1"):
gevent.sleep(1.1) # wait until the DeviceProxy becomes useable again
with caplog.at_level(logging.DEBUG, logger="global.controllers.lima_simulator"):
scan = loopscan(1, 0.1, simulator, save=False)
assert "All parameters will be refeshed on lima_simulator" in caplog.messages
with pytest.raises(DevFailed):
caplog.clear()
with caplog.at_level(logging.DEBUG, logger="global.controllers.lima_simulator"):
scan = loopscan(1, 0.1, simulator, save=False)
with lima_simulator_context("simulator", "id00/limaccds/simulator1"):
gevent.sleep(1.1) # wait until the DeviceProxy becomes useable again
caplog.clear()
with caplog.at_level(logging.DEBUG, logger="global.controllers.lima_simulator"):
> scan = loopscan(1, 0.1, simulator, save=False)
tests/controllers_sw/test_lima_simulator.py:877:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:897: in wrapped_function
)(function)(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:843: in wrapped_function
return function(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:808: in wrapped_function
return function(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/typeguard/__init__.py:784: in wrapper
retval = func(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/scans/step_by_step.py:1159: in loopscan
scan_info=scan_info,
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:897: in wrapped_function
)(function)(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:843: in wrapped_function
return function(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/utils.py:808: in wrapped_function
return function(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/typeguard/__init__.py:784: in wrapper
retval = func(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/scans/step_by_step.py:1093: in timescan
scan.run()
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/scanning/scan.py:1544: in run
self._cache_cnx.disable_caching()
/opt/conda/envs/testenv/lib/python3.7/contextlib.py:119: in __exit__
next(self.gen)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/cleanup.py:286: in capture_exceptions
raise value
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/common/cleanup.py:262: in capture
yield
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/scanning/scan.py:1418: in run
self.prepare(self.scan_info, self.acq_chain._tree)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/scanning/scan.py:1236: in prepare
self._prepare_devices(devices_tree)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/scanning/scan.py:1252: in _prepare_devices
dev.name, parent=parent_node, connection=self._cache_cnx
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/data/node.py:208: in _create_node
return _get_node_object(node_type, name, parent, connection, create=True, **keys)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/data/node.py:110: in _get_node_object
node_type, name, parent, connection=connection, create=create, **keys
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/data/node.py:706: in __init__
**keys,
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/data/node.py:275: in __init__
self._struct = self._create_struct(db_name, name, node_type)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/data/node.py:349: in _create_struct
struct.name = name
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings.py:1170: in __setattr__
self._proxy[name] = value
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings.py:677: in __setitem__
cnx.hset(self.name, key, value)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings_cache.py:49: in f
return func(self, *args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings_cache.py:385: in hset
cached_dict = self._get_cache_dict(name)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings_cache.py:515: in _get_cache_dict
cached_dict = self._fill_cache(name, self.TYPE.HASH)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings_cache.py:61: in f
return func(self, *args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/bliss/config/settings_cache.py:565: in _fill_cache
conn, pipeline.command_stack, True
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/client.py:3888: in _execute_transaction
self.parse_response(connection, '_')
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/client.py:3972: in parse_response
self, connection, command_name, **options)
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/client.py:915: in parse_response
response = connection.read_response()
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/connection.py:730: in read_response
response = self._parser.read_response()
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/connection.py:464: in read_response
self.read_from_socket()
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/connection.py:421: in read_from_socket
bufflen = recv_into(self._sock, self._buffer)
/opt/conda/envs/testenv/lib/python3.7/site-packages/redis/_compat.py:75: in recv_into
return sock.recv_into(*args, **kwargs)
/opt/conda/envs/testenv/lib/python3.7/site-packages/gevent/_socket3.py:509: in recv_into
self._wait(self._read_event)
src/gevent/_hub_primitives.py:317: in gevent._gevent_c_hub_primitives.wait_on_socket
???
src/gevent/_hub_primitives.py:322: in gevent._gevent_c_hub_primitives.wait_on_socket
???
src/gevent/_hub_primitives.py:304: in gevent._gevent_c_hub_primitives._primitive_wait
???
src/gevent/_hub_primitives.py:46: in gevent._gevent_c_hub_primitives.WaitOperationsGreenlet.wait
???
src/gevent/_hub_primitives.py:46: in gevent._gevent_c_hub_primitives.WaitOperationsGreenlet.wait
???
src/gevent/_hub_primitives.py:55: in gevent._gevent_c_hub_primitives.WaitOperationsGreenlet.wait
???
src/gevent/_waiter.py:151: in gevent._gevent_c_waiter.Waiter.get
???
src/gevent/_greenlet_primitives.py:61: in gevent._gevent_c_greenlet_primitives.SwitchOutGreenletWithLoop.switch
???
src/gevent/_greenlet_primitives.py:61: in gevent._gevent_c_greenlet_primitives.SwitchOutGreenletWithLoop.switch
???
src/gevent/_greenlet_primitives.py:65: in gevent._gevent_c_greenlet_primitives.SwitchOutGreenletWithLoop.switch
???
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> ???
E greenlet.error: cannot switch to a different thread
src/gevent/_gevent_c_greenlet_primitives.pxd:35: error