Skip to content

pip.parse fails when timeout is passed to underlying whl_archive targets #4077

Closed

Description

@nate-england

🐞 bug report

Affected Rule

The issue is caused by the rule:

See https://github.com/bazel-contrib/rules_python/pull/3948/changes#r3800974643

Is this a regression?

Yes, the previous version in which this bug was not present was: ....

Yes, pip.parse accepted timeouts like the docs mention

Description

A clear and concise description of the problem...

On the tin

🔬 Minimal Reproduction

pip.parse with experimental_index_url and timeout specified breaks this

🔥 Exception or Error





(00:01:57) ERROR: /home/nathanael/.cache/bazel/_bazel_nathanael/f057a3c2a08c6c9f1c59ae3fa9073646/external/rules_python+/python/private/pypi/extension.bzl:615:20: @@rules_python+//python/extensions:rules_python++pip+pypi_312_absl_py_py3_none_any_88476fd8: no such attribute 'timeout' in 'whl_archive' rule
(00:01:57) ERROR: /home/nathanael/.cache/bazel/_bazel_nathanael/f057a3c2a08c6c9f1c59ae3fa9073646/external/rules_python+/python/private/pypi/whl_library.bzl:815:20: Traceback (most recent call last):
	File "/home/nathanael/.cache/bazel/_bazel_nathanael/f057a3c2a08c6c9f1c59ae3fa9073646/external/rules_python+/python/private/pypi/extension.bzl", line 615, column 20, in _pip_impl
		whl_library(name = name, **args)
	File "/home/nathanael/.cache/bazel/_bazel_nathanael/f057a3c2a08c6c9f1c59ae3fa9073646/external/rules_python+/python/private/pypi/whl_library.bzl", line 815, column 20, in whl_library
		whl_archive(name = name, **kwargs)
Error in repository_rule: failed to instantiate 'whl_archive' from this module extension

🌍 Your Environment

Operating System:

  
Ubuntu 24.04
  

Output of bazel version:

  
8.7.0
  

Rules_python version:

  
2.3.0
  

Activity

  1. added theissue type on Aug 18, 2026
  2. honnix commented on Aug 18, 2026

    @honnix

    Looks like the same for environment.

  3. aignas commented on Aug 19, 2026

    @aignas
    Collaborator

    The correct fix here would be to modify the hub_builder.bzl file. PRs are welcome.

  4. aignas commented on Aug 20, 2026

    @aignas
    Collaborator

    Decided to drop the args on the whl_library side. The hub builder can be modified later.

  5. added a commit that references this issue on Aug 20, 2026
    b1b9bf0
  6. honnix commented on Aug 20, 2026

    @honnix

    Looks like the same for environment.

    Sorry I misunderstood this issue. In our case, pip.parse environment attr not forwarded to whl_archive.

  7. aignas commented on Aug 21, 2026

    @aignas
    Collaborator

    @honnix, could you please create a ticket with what has regressed just to ensure that we understand the impact? Is it for envsubst?

  8. honnix commented on Aug 21, 2026

    @honnix

    @aignas NVM, I think the fix should work for environment as well since it is not supposed to be passed to whl_archive, so the filtering will fix.

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions