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: pyc files in Meson mesonbuild repo causing rebuilds #1343

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jjmaestro
Copy link
Contributor

Fixes #1342

It seems that pyc files appear in the Meson repo between the first and second time a python toolchain is used and if these are not excluded, the new pyc files invalidate dependent rules, forcing a rebuild.

For more context, see #1342 and Slack 🧵.

Fixes bazel-contrib#1342

It seems that pyc files appear in the Meson repo between the first and
second time a python toolchain is used and if these are not excluded,
the new pyc files invalidate dependent rules, forcing a rebuild.

For more context, see bazel-contrib#1342 and
https://bazelbuild.slack.com/archives/CA306CEV6/p1734196424601509
@jjmaestro jjmaestro force-pushed the fix-meson-pyc-rebuilds branch from 0d06352 to 4a1c8e9 Compare December 18, 2024 12:50
@jjmaestro
Copy link
Contributor Author

I force-pushed the same commit to re-trigger the checks but they all seem to be failing for some reason :( I'll investigate and see if I can fix it in another PR!

@jsharpe
Copy link
Member

jsharpe commented Dec 18, 2024

Its because CI has upgraded to bazel 8 - I've started fixing it here: #1340 but need to wait for bazel 8.0.1 as theres a regression with respect to handling of $(location) that is returning more than one file now.

@jsharpe
Copy link
Member

jsharpe commented Dec 18, 2024

The fix seems sensible to me though, although like you I'd like to know why its necessary!

@jjmaestro
Copy link
Contributor Author

The fix seems sensible to me though, although like you I'd like to know why its necessary!

Yeah, totally 😅

From what I gathered, there's a bunch of issues with the pyc files but what really surprises me is the Python version in those files... the fact that it seems to be compiled with the standalone interpreter and not with the Python version that's selected in the toolchain.

But alas, I think this is as good as it gets! Maybe when I learn more about how Bazel & some of the rules work I'll have an aha! moment 😄

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.

pyc files in Meson mesonbuild repo causing rebuilds
2 participants