there seems to be a general problem in the interaction between PVector from Pyrsistent and pykka Since Python 3.8, causing recursion errors of the form:
onsite_1 | Traceback (most recent call last):
onsite_1 | File "/ems/onsite/main.py", line 49, in <module>
onsite_1 | _cls_operator = CLSOperator.new(_cls, _notifier)
onsite_1 | File "/ems/cls/operator.py", line 175, in new
onsite_1 | actor.update_cls(pvector(ecls)).get() # sync up
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_threading.py", line 55, in get
onsite_1 | raise exc_value
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_actor.py", line 186, in _actor_loop
onsite_1 | response = self._handle_receive(envelope.message)
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_actor.py", line 286, in _handle_receive
onsite_1 | return callee(*message.args, **message.kwargs)
onsite_1 | File "/ems/cls/operator.py", line 78, in update_cls
onsite_1 | self.reset_proxies()
onsite_1 | File "/ems/cls/operator.py", line 95, in reset_proxies
onsite_1 | self.proxies = [CLSProxy.new(channel(cls)) for cls in self.cls_set]
onsite_1 | File "/ems/cls/operator.py", line 95, in <listcomp>
onsite_1 | self.proxies = [CLSProxy.new(channel(cls)) for cls in self.cls_set]
onsite_1 | File "/ems/cls/operator.py", line 93, in channel
onsite_1 | return PresentCLSStateChannel.new(_present_cls_state_channel_seal, cls, self.actor_ref.proxy())
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_ref.py", line 170, in proxy
onsite_1 | return ActorProxy(self)
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 124, in __init__
onsite_1 | self._known_attrs = self._introspect_attributes()
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 141, in _introspect_attributes
onsite_1 | if self._is_self_proxy(attr):
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 173, in _is_self_proxy
onsite_1 | return attr == self
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pyrsistent/_pvector.py", line 81, in __eq__
onsite_1 | return self is other or (hasattr(other, '__len__') and self._count == len(other)) and compare_pvector(self, other, operator.eq)
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 215, in __getattr__
onsite_1 | if attr_path not in self._known_attrs:
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 215, in __getattr__
onsite_1 | if attr_path not in self._known_attrs:
onsite_1 | File "/opt/venv/lib/python3.8/site-packages/pykka/_proxy.py", line 215, in __getattr__
onsite_1 | if attr_path not in self._known_attrs:
onsite_1 | [Previous line repeated 980 more times]
onsite_1 | RecursionError: maximum recursion depth exceeded
Seems like generally the problem does not occur when wrapping PVector as fields