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

Fix intermittent PEP-517 failures. #2540

Merged
merged 1 commit into from
Sep 19, 2024
Merged

Conversation

jsirois
Copy link
Member

@jsirois jsirois commented Sep 19, 2024

I've not had a report in the wild, but CI intermittently fails in
PEP-517 tests, not finding the json communication file on the read end.
This exposes a race where the PEP-517 process completes before the
temporary file context manager is exited and the communication file,
with the results therein, is deleted before it can be read. Switch from
a temporary file that deletes on context exit (it's amazing this worked
as reliably as it did - it was a bug from day 1!) to one that deletes
only upon the Pex process exit.

I've not had a report in the wild, but CI intermittently fails in
PEP-517 tests, not finding the json communication file on the read end.
This exposes a race where the PEP-517 process completes before the
temporary file context manager is exited and the communication file,
with the results therein, is deleted before it can be read. Switch from
a temporary file that deletes on context exit (it's amazing this worked
as reliably as it did - it was a bug from day 1!) to one that deletes
only upon the Pex process exit.
jsirois added a commit to jsirois/pex that referenced this pull request Sep 19, 2024
@jsirois jsirois merged commit f5be479 into pex-tool:main Sep 19, 2024
26 checks passed
@jsirois jsirois deleted the pep_517/fix branch September 19, 2024 02:44
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