Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ci differences #238

Closed
wants to merge 3 commits into from
Closed

Ci differences #238

wants to merge 3 commits into from

Conversation

liamhuber
Copy link
Member

In pyiron_workflow I'm running into a problem where the tests hang, and when cancelled I ultimately get pympipool complaints that the test files were not importable modules.

I found these lines where "." is getting added to the pythonpath (similar for mpiexec), and notice that pympipool workflows follow a pattern of cd tests; python -m unittest discover ., while the centralized workflows skip the CI and simply invoke things in the pattern python -m unittest discover tests. From my experiments in pyiron_workflow it looks like this is what's making the difference.

Here I want to double check that hypothesis and test two-work arounds. If the hypothesis is correct, I'll open a corresponding issue.

I expect this to hang indefinitely and ultimately fail with `ModuleNotFoundError`, if my experience in pyiron_workflow is anything to go by.
I'm not sure either of these will work, but both follow the idea of making sure that the global system path can make up for the fact that we don't cd before discovering tests
So we can actually find them!
@liamhuber
Copy link
Member Author

Unittests_by_path fails as anticipated:

Traceback (most recent call last):
  File "/home/runner/work/pympipool/pympipool/pympipool/backend/mpiexec.py", line 90, in <module>
    main()
  File "/home/runner/work/pympipool/pympipool/pympipool/backend/mpiexec.py", line 46, in main
    input_dict = interface_receive(socket=socket)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/share/miniconda3/envs/test/lib/python3.11/site-packages/pympipool/shared/communication.py", line 147, in interface_receive
    return cloudpickle.loads(socket.recv())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'test_meta'
Error: The action has timed out.

Here it sensibly has a timeout set and fails cleanly instead of hanging forever, which is a minor improvement I can learn for the pyiron_workflow tests.

Very nicely, both versions of my "patch" to the environment passed and facilitate discovering the tests by a path.

This can be closed, but I'll leave it open until the corresponding issue is resolved in case that has any impact on viewing the test logs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant