@@ -380,11 +380,15 @@ def lock(
380380 action.
381381 - `name.run`: a runnable target that can be used to pass extra parameters
382382 to the same command that would be run in the `name` action. This will
383- update the source copy of the requirements file.
383+ update the source copy of the requirements file. You can customize the
384+ args via the command line, but it requires being able to run `uv` (and
385+ possibly `python`) directly on your host.
384386 - `name.update`: a target that can be run to update the source-tree version
385387 of the requirements lock file. The output can be fed to the
386388 {obj}`pip.parse` bzlmod extension tag class. Note, you can use
387- `native_test` to wrap this target to make a test.
389+ `native_test` to wrap this target to make a test. You can't customize the
390+ args via command line, but you can use RBE to generate requirements
391+ (offload execution and run for different platforms)
388392
389393 Args:
390394 name: {type}`str` The prefix of all targets created by this macro.
@@ -440,7 +444,6 @@ def lock(
440444 update_target = update_target ,
441445 output = out ,
442446 tags = [
443- "local" ,
444447 "manual" ,
445448 "no-cache" ,
446449 "requires-network" ,
@@ -463,16 +466,18 @@ def lock(
463466 # FIXME @aignas 2025-03-20: is it possible to extend `py_binary` so that the
464467 # srcs are generated before `py_binary` is run? I found that
465468 # `ctx.files.srcs` usage in the base implementation is making it difficult.
469+ template_target = "_{}_gen" .format (name )
466470 _expand_template (
467- name = name + "_cp" ,
471+ name = template_target ,
468472 src = name ,
469473 output = out ,
470474 update_target = update_target ,
475+ tags = ["manual" ],
471476 )
472477
473478 py_binary (
474479 name = update_target ,
475- srcs = [name + "_cp" ],
480+ srcs = [template_target ],
476481 data = [name ] + ([maybe_out ] if maybe_out else []),
477482 tags = ["manual" ],
478483 )
0 commit comments