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

gh-123085: _compile_importlib: Avoid copying sources before compilation #124131

Merged
merged 4 commits into from
Sep 18, 2024

Conversation

encukou
Copy link
Member

@encukou encukou commented Sep 16, 2024

Make the test helper compile directly from the “installed” sources.
This should avoid doing some unnecessary work, as well as possible issues in copying too much/too little metadata to a different filesystem. Hopefully, it'll fix the buildbot failure.

@encukou
Copy link
Member Author

encukou commented Sep 16, 2024

This now doesn't copy resources of importlib.resources, which we currently don't have.
Assuming the overall approach is fine, would it be OK to mention resources in a comment, or should this also copy non-.py files? Either way, there's no good way to test what would happen if some resources were there.

@encukou
Copy link
Member Author

encukou commented Sep 16, 2024

!buildbot fedora

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @encukou for commit cade8d2 🤖

The command will test the builders whose names match following regular expression: fedora

The builders matched are:

  • s390x Fedora Clang PR
  • PPC64LE Fedora Stable Clang Installed PR
  • s390x Fedora Rawhide Clang Installed PR
  • s390x Fedora LTO + PGO PR
  • AMD64 Fedora Stable Clang PR
  • aarch64 Fedora Rawhide PR
  • PPC64 Fedora PR
  • aarch64 Fedora Rawhide LTO + PGO PR
  • PPC64LE Fedora Rawhide LTO + PGO PR
  • AMD64 Fedora Rawhide NoGIL refleaks PR
  • aarch64 Fedora Rawhide Refleaks PR
  • s390x Fedora Rawhide Clang PR
  • AMD64 Fedora Stable LTO PR
  • PPC64LE Fedora Rawhide PR
  • aarch64 Fedora Stable Refleaks PR
  • aarch64 Fedora Stable PR
  • s390x Fedora PR
  • aarch64 Fedora Stable Clang PR
  • s390x Fedora Clang Installed PR
  • AMD64 Fedora Rawhide Refleaks PR
  • PPC64LE Fedora Rawhide NoGIL refleaks PR
  • PPC64LE Fedora Stable Clang PR
  • PPC64LE Fedora Stable LTO PR
  • aarch64 Fedora Rawhide NoGIL PR
  • PPC64LE Fedora Rawhide Refleaks PR
  • AMD64 Fedora Rawhide NoGIL PR
  • AMD64 Fedora Stable PR
  • aarch64 Fedora Stable LTO + PGO PR
  • AMD64 Fedora Rawhide PR
  • PPC64LE Fedora Rawhide Clang PR
  • s390x Fedora Refleaks PR
  • aarch64 Fedora Rawhide Clang PR
  • s390x Fedora LTO PR
  • PPC64LE Fedora Rawhide Clang Installed PR
  • PPC64LE Fedora Rawhide LTO PR
  • s390x Fedora Rawhide LTO + PGO PR
  • PPC64LE Fedora Stable Refleaks PR
  • PPC64LE Fedora Stable PR
  • aarch64 Fedora Stable LTO PR
  • AMD64 Fedora Rawhide LTO PR
  • AMD64 Fedora Stable Clang Installed PR
  • AMD64 Fedora Rawhide Clang PR
  • aarch64 Fedora Rawhide NoGIL refleaks PR
  • PPC64LE Fedora Stable LTO + PGO PR
  • aarch64 Fedora Rawhide LTO PR
  • PPC64LE Fedora Rawhide NoGIL PR
  • aarch64 Fedora Rawhide Clang Installed PR
  • s390x Fedora Rawhide PR
  • s390x Fedora Rawhide LTO PR
  • aarch64 Fedora Stable Clang Installed PR
  • AMD64 Fedora Stable LTO + PGO PR
  • AMD64 Fedora Rawhide LTO + PGO PR
  • AMD64 Fedora Rawhide Clang Installed PR
  • AMD64 Fedora Stable Refleaks PR
  • s390x Fedora Rawhide Refleaks PR

@encukou encukou marked this pull request as ready for review September 17, 2024 09:01
@jaraco
Copy link
Member

jaraco commented Sep 17, 2024

!buildbot fedora

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @jaraco for commit 8cd8fe9 🤖

The command will test the builders whose names match following regular expression: fedora

The builders matched are:

  • s390x Fedora Clang PR
  • PPC64LE Fedora Stable Clang Installed PR
  • s390x Fedora Rawhide Clang Installed PR
  • s390x Fedora LTO + PGO PR
  • AMD64 Fedora Stable Clang PR
  • aarch64 Fedora Rawhide PR
  • PPC64 Fedora PR
  • aarch64 Fedora Rawhide LTO + PGO PR
  • PPC64LE Fedora Rawhide LTO + PGO PR
  • AMD64 Fedora Rawhide NoGIL refleaks PR
  • aarch64 Fedora Rawhide Refleaks PR
  • s390x Fedora Rawhide Clang PR
  • AMD64 Fedora Stable LTO PR
  • PPC64LE Fedora Rawhide PR
  • aarch64 Fedora Stable Refleaks PR
  • aarch64 Fedora Stable PR
  • s390x Fedora PR
  • aarch64 Fedora Stable Clang PR
  • s390x Fedora Clang Installed PR
  • AMD64 Fedora Rawhide Refleaks PR
  • PPC64LE Fedora Rawhide NoGIL refleaks PR
  • PPC64LE Fedora Stable Clang PR
  • PPC64LE Fedora Stable LTO PR
  • aarch64 Fedora Rawhide NoGIL PR
  • PPC64LE Fedora Rawhide Refleaks PR
  • AMD64 Fedora Rawhide NoGIL PR
  • AMD64 Fedora Stable PR
  • aarch64 Fedora Stable LTO + PGO PR
  • AMD64 Fedora Rawhide PR
  • PPC64LE Fedora Rawhide Clang PR
  • s390x Fedora Refleaks PR
  • aarch64 Fedora Rawhide Clang PR
  • s390x Fedora LTO PR
  • PPC64LE Fedora Rawhide Clang Installed PR
  • PPC64LE Fedora Rawhide LTO PR
  • s390x Fedora Rawhide LTO + PGO PR
  • PPC64LE Fedora Stable Refleaks PR
  • PPC64LE Fedora Stable PR
  • aarch64 Fedora Stable LTO PR
  • AMD64 Fedora Rawhide LTO PR
  • AMD64 Fedora Stable Clang Installed PR
  • AMD64 Fedora Rawhide Clang PR
  • aarch64 Fedora Rawhide NoGIL refleaks PR
  • PPC64LE Fedora Stable LTO + PGO PR
  • aarch64 Fedora Rawhide LTO PR
  • PPC64LE Fedora Rawhide NoGIL PR
  • aarch64 Fedora Rawhide Clang Installed PR
  • s390x Fedora Rawhide PR
  • s390x Fedora Rawhide LTO PR
  • aarch64 Fedora Stable Clang Installed PR
  • AMD64 Fedora Stable LTO + PGO PR
  • AMD64 Fedora Rawhide LTO + PGO PR
  • AMD64 Fedora Rawhide Clang Installed PR
  • AMD64 Fedora Stable Refleaks PR
  • s390x Fedora Rawhide Refleaks PR

@jaraco
Copy link
Member

jaraco commented Sep 17, 2024

I pushed a new commit to trim down the logic substantially. Let me know what you think.

@encukou
Copy link
Member Author

encukou commented Sep 18, 2024

Looks good, thank you!

@encukou encukou merged commit 42c8b05 into python:main Sep 18, 2024
87 of 88 checks passed
@encukou encukou deleted the compile-importlib branch September 18, 2024 12:14
@jaraco
Copy link
Member

jaraco commented Sep 19, 2024

I cherry-picked the change to python/importlib_resources@cc5d9cbb6e.

savannahostrowski pushed a commit to savannahostrowski/cpython that referenced this pull request Sep 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants