Skip to content

ERROR from re2 with bazel 8.0 and bazel mod graph #525

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

Open
carpenterjc opened this issue Dec 20, 2024 · 4 comments
Open

ERROR from re2 with bazel 8.0 and bazel mod graph #525

carpenterjc opened this issue Dec 20, 2024 · 4 comments

Comments

@carpenterjc
Copy link

After upgrading to bazel 8.0.0 I have noticed re2 gives an error in bazel mod graph this previous worked.

D:\g\re2>bazel mod graph
Starting local Bazel server and connecting to it...
WARNING: For repository 'rules_cc', the root module requires module version [email protected], but got [email protected] in the resolved dependency graph. Please update the version in your MODULE.bazel or set --check_direct_dependencies=off
WARNING: For repository 'rules_python', the root module requires module version [email protected], but got [email protected] in the resolved dependency graph. Please update the version in your MODULE.bazel or set --check_direct_dependencies=off
ERROR: @@bazel_tools//tools/cpp:cc_configure.bzl does not export a module extension called cc_configure_extension, yet its use is requested at D:/g/re2/MODULE.bazel:22:29

If you switch back to bazel 7.3.2 for example it works.

This is reproducible by running bazel mod graph on the re2 repo directly, but it will give this message with anything which depends on re2.

@carpenterjc
Copy link
Author

I believe this is the line and it looks like with bazel 8 it either isn't needed or needs an alternative solution.
https://github.com/google/re2/blob/main/MODULE.bazel#L22
@junyer seems to be mentioned in the comment.

@notxvilka
Copy link

Just met the same error. As Bazel 8.x is out of the bag, it is important to have this one fixed since the re2 is quite popular dependency.

@jmr
Copy link
Member

jmr commented Feb 28, 2025

This has been fixed by c84a140.

moroten pushed a commit to buildbarn/bb-deployments that referenced this issue Mar 11, 2025
A fix has been published, we can override the version until a new release is made to the BCR.

See also
google/re2#525
@j2kun
Copy link

j2kun commented Mar 19, 2025

This also prevents one from running, say, bazel mod deps, so any project which transitively depends on re2 cannot run this to update their lockfile dependencies.

Is it possible to get a release pushed for this?

Edit: I copied @moroten's patch in buildbarn/bb-deployments@9f79d37 Thanks!

j2kun added a commit to j2kun/heir that referenced this issue Mar 19, 2025
Add gitattributes for bazel-provided merge conflict resolution
in the lockfile.

Added a patch to re2 (transitive dep via or-tools)
due to google/re2#525

Extracted from google#1552
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

No branches or pull requests

4 participants