Skip to content

name 'flag_alias' is not defined for bazel 7.0.0 and 8.0.0 #4478

Closed as not planned

Description

@TendTo

🐞 bug report

Affected Rule

The whole rules_python package is affected.

Is this a regression?

Yes, in a sense. This was probably introduced in #3450 .

Description

Trying to run any rule from rules_python with bazel versions 7.0.0 or 8.0.0 will produce the error

ERROR: https://bcr.bazel.build/modules/rules_python/2.4.6/MODULE.bazel:380:1: name 'flag_alias' is not defined
ERROR: Error computing the main repository mapping: in module dependency chain <root> -> rules_python@2.4.6: syntax error in MODULE.bazel file for rules_python@2.4.6

🔬 Minimal Reproduction

Any project using bazel from 7.0.0 or 8.0.0 until the bazel version that introduced the flag_alias function. Note that bazel 7.x and bazel 8.x work.
Bazel 9.0.0 and following are not affected.

🔥 Exception or Error

ERROR: https://bcr.bazel.build/modules/rules_python/2.4.6/MODULE.bazel:380:1: name 'flag_alias' is not defined
ERROR: Error computing the main repository mapping: in module dependency chain <root> -> rules_python@2.4.6: syntax error in MODULE.bazel file for rules_python@2.4.6

🌍 Your Environment

Operating System:

  
Linux
  

Output of bazel version:

  
bazel 7.0.0
bazel 8.0.0
  

Rules_python version:

  
2.4.6
  

Anything else relevant?

If there is no interest in supporting bazel 7.0.0 and 8.0.0, it may be useful to indicate which versions are supported more precisely.

Activity

  1. aignas commented on Nov 12, 2026

    @aignas
    Collaborator

    FYI, in here we advertise we support 7.4.1 and later.

    The promise is to support a reasonable 8.x and 7.x version, whilst we don't necessarily support only the latest version, but we definitely do not intend to support 7.0.0 and 8.0.0 because they are buggy. Happy to receive PRs to clarify parts of the docs if you find them not useful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions