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

Fixes for Windows PyPy 3.6 #2363

Merged
merged 1 commit into from
Jun 24, 2022
Merged

Fixes for Windows PyPy 3.6 #2363

merged 1 commit into from
Jun 24, 2022

Conversation

reksar
Copy link
Contributor

@reksar reksar commented Jun 18, 2022

This seems to be a separate issue with Windows PyPy 3.6

I ran tests/unit/create/test_creator.py in Windows PyPy 3.6 (v7.3.3) and got errors in the same tests as CI, except test_create_distutils_cfg[venv] that passes locally and fails on CI, most likely due to timeout.

Local tests fails when the test_create_no_seed[venv*] checks exe files, but CI errors causes when same tests find an exception in creator.debug:

{
  "err": "The system cannot find the file specified",
  "exception": "SyntaxError('invalid syntax', ('<unknown>', 0, 1, '\\n', 0))", 
  "out": "",
  "returncode": 2
}

The SyntaxError was happened in creator.py because of literal_eval(out) when out is empty.

I can't reproduce the exception locally, but I modified the debug info to look something like:

{
  "err": "[Errno 2] The system cannot find the file specified: '<file>'",
  "exception": "OSError<...>", 
  "out": "",
  "returncode": 2
}

Windows PyPy <= 3.6 contains only pypy3.exe and pypy3w.exe and creating a virtual environment with venv does not hanlde missing executables, e.g. python.exe. Also, the stdlib path for old PyPy versions is <host>\site-packages instead of <host>\Lib\site-packages.

Local tests failures are fixed by creating missing executables.

Test coverage calculation is fixed by adding stdlib path for old PyPy versions into .coveragerc sources.

Copy link
Contributor

@gaborbernat gaborbernat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also passes unit tests in test_creator.py
@reksar
Copy link
Contributor Author

reksar commented Jun 24, 2022

😀
I believe we'll catch the bug.

@gaborbernat
Copy link
Contributor

I believe we'll catch the bug.

Catch as in?

@reksar
Copy link
Contributor Author

reksar commented Jun 24, 2022

Windows PyPy 3.6 test may throw an OSError to be fixed further.

@gaborbernat
Copy link
Contributor

Can you fix it? 😆

@reksar
Copy link
Contributor Author

reksar commented Jun 24, 2022

Yes. I'll check logs and do my best)

@gaborbernat
Copy link
Contributor

Thanks, will cut a release once we fix it 👍

@reksar reksar mentioned this pull request Jun 24, 2022
5 tasks
@gaborbernat gaborbernat merged commit b01515b into pypa:main Jun 24, 2022
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.

None yet

2 participants