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

Make test egg generation more reliable #499

Merged
merged 1 commit into from
Jan 20, 2023

Conversation

swt2c
Copy link
Contributor

@swt2c swt2c commented Jan 11, 2023

  1. Use sys.executable instead of 'python' to generate eggs to ensure the eggs are generated for the currently running python version.

  2. Ensure the egg generation is run with a clean environment (stray environment variables caused problems on Debian, for instance).

@mdickinson
Copy link
Member

Thanks for the contribution! It looks as though we've got failures on Windows; I'll investigate at some point.

At a guess, there's some part of the environment that we do need to pass on for things to work on Windows.

@mdickinson
Copy link
Member

I dug into the Windows failures a bit last night, on a Windows VM. The tests failed for me, but not in exactly the same way as above.

@swt2c Would you object to me breaking off the sys.executable change into a separate PR? That part's a clear bug, and should be an easy fix. The environment manipulation is looking more involved.

@swt2c
Copy link
Contributor Author

swt2c commented Jan 13, 2023

No objections here. I was planning to look into the Windows issue further myself, or perhaps I could figure out which environment variable(s) are causing problems on Debian and just remove those? It's possible the problems I'm seeing are Debian specific, as I didn't see any problems on Fedora after I switched to sys.executable.

Use sys.executable instead of 'python' to generate eggs to ensure the
eggs are generated for the currently running python version.
@swt2c swt2c force-pushed the fix_test_egg_generation branch from da00e5a to 1da6104 Compare January 20, 2023 00:13
@swt2c
Copy link
Contributor Author

swt2c commented Jan 20, 2023

I removed the env change for now and just left the sys.executable one.

Copy link
Member

@mdickinson mdickinson left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you!

@mdickinson
Copy link
Member

I've opened #501 for the environment variable issue. At least on Windows + EDM that's probably one that needs internal investigation.

@mdickinson mdickinson merged commit 301c2ab into enthought:main Jan 20, 2023
mdickinson pushed a commit that referenced this pull request Feb 6, 2023
Uses sys.executable instead of 'python' to generate eggs to ensure the
eggs are generated for the currently running python version.

(cherry picked from commit 301c2ab)
mdickinson pushed a commit that referenced this pull request Feb 7, 2023
Uses sys.executable instead of 'python' to generate eggs to ensure the
eggs are generated for the currently running python version.

(cherry picked from commit 301c2ab)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants