-
Notifications
You must be signed in to change notification settings - Fork 40
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
Python broke in v2.5.0 #167
Comments
@lazka, I guess we need to have some packages regenerated on the new setup? That is, this issue is transitory because some packages were built with the old setup but are being executed on the new. |
If any package 'knows' the GHA path and doesn't work elsewhere, that package is broken, because a user is unlikely to install msys2 in |
@jeremyd2019 maybe it's the cache of their MSYS2 job in CI the one remembering old paths? |
I guess the problem is this: https://github.com/cocotb/cocotb/blob/0346c035f0e1fac432c5a35ea38b95787e7d7223/cocotb/share/makefiles/Makefile.inc#L74 (why no one else has the problem) This returns the wrong path, needs investigating:
I'm not sure if prefix is supposed to be relocated though, seems to be an autotools path. |
Maybe we should support optionally specifying |
* Workaround for msys2/setup-msys2#167 * Adapted from cocotb/cocotb@05036cb
No, this is unrelated to this action. It would fail the same way outside of CI. I've created msys2-contrib/cpython-mingw#51 |
@lazka my point is that this did not arise before because the prefix did match (when building Python in CI and when using it in CI). As soon as Python is updated using the new CI setup, the cocotb CI will work again. However, that does not imply fixing msys2-contrib/cpython-mingw#51. If cocotb could use a different absolute path for their regular CI, future issues such as this would be found. |
Ah, I see. Or we could use a different path in autobuild. |
* Workaround for msys2/setup-msys2#167 * Adapted from cocotb/cocotb@05036cb
@lazka Read this: https://docs.python.org/3/using/cmdline.html#envvar-PYTHONHOME. |
…ce tests (to workaround msys2/setup-msys2#167)
* msys ci: un-pin setup-msys2 action version * msys ci: explicitly set PYTHONHOME and PYTHONPATH for c++ and interface tests (to workaround msys2/setup-msys2#167)
I've compiled >>> import sys
>>> print(sys.path)
['', 'C:/msys64/mingw64/lib/python311.zip', 'C:/msys64/mingw64/lib/python3.11', 'C:/msys64/mingw64/lib/python3.11/lib-dynload', 'C:/msys64/mingw64/lib/python3.11/site-packages'] However, when running in :py3 import sys; print(sys.path)
>>> Could not find platform dependent libraries <exec_prefix>
>>>['C:/msys64/mingw64/lib/python311.zip', 'C:/msys64/mingw64/lib/python3.11', 'D:/a/msys64/mingw64/lib/python3.11/lib-dynload', 'C:/msys64/mingw64/lib/python3.11/site-packages', '_vim_path_'] This bars importing some stdlib components like the Perhaps the issue here lies in where the DLL gets loaded from? Seems to be related to this though EDIT: compiling with the |
The release v2.5.0 broke running Python in GH Actions with under msys, it worked in 2.4.2.
Our workflow:
https://github.com/cocotb/cocotb/blob/1123973ed6979f89b8e1cb8785d5ae7c425d2908/.github/workflows/regression-tests.yml#L334-L371
Python aborts execution right after start with the following message:
There's much more information available at cocotb/cocotb#2739
The most likely reason for this change in behavior seems to be like #163. Do you have any idea what's going on?
Note PYTHONHOME is referring to (as far as I read the PR) the "old" installation path, 'D:/a/_temp/msys/msys64/mingw64', while the Python binary is in the new installation path.
The text was updated successfully, but these errors were encountered: