Skip to content

Unable to get jobs running on nodes #6

@BasilLiekens

Description

@BasilLiekens

Brief

Using the basic examples from the tutorials, simulations went just fine, but when trying to perform python manage.py <network_name> run, dispy manages to connect to the nodes and identify them correctly, then silently fails. When enabling the debug info, it becomes clear the issue is because of the unpickling failing.

Version information

Python version: 3.10.15 (python function getargspec was removed in python 3.11, so 3.10 is the highest possible option)
Relevant pip packages:

dispy==4.12.3
pycos==4.12.2

Specific error trace

DEBUG ->  DispyJob running with ID 1
DEBUG ->  Job SourceJob 1 terminated on node 192.168.1.103
DEBUG ->  With error:
Traceback (most recent call last):
  File "/home/RPi/installations/.venv/bin/dispynode.py", line 219, in _dispy_job_func
    localvars = {'dispy_job_args': deserialize(__dispy_job_args),
  File "/home/RPi/installations/.venv/lib/python3.10/site-packages/pycos/__init__.py", line 85, in deserialize
    return pickle.loads(pkl)
ModuleNotFoundError: No module named 'example_1'

Remedies tried

  • Changed import pickle to import pickle5 as pickle in /path/to/venv/lib/python3.10/site-packages/pycos/__init__.py
  • Changed version of dispy to more recent ones (4.15.1 and 4.15.2), but then the function dispynode.py would not even properly start, which is a requirement for the communication to work.
  • Copied over the relevant project folder to the RPi (in the folder with the venv that contains dispy) prior to invoking python manage.py <network_name> run, to allow Pickle to acces the modules it states it is missing)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions