• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pantsbuild / pants / 24699019654 / 5
93%
main: 91%

Build:
Build:
LAST BUILD BRANCH: arm64_on_depot
DEFAULT BRANCH: main
Ran 21 Apr 2026 01:39AM UTC
Files 1173
Run time 35s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Apr 2026 01:19AM UTC coverage: 52.375% (-0.002%) from 52.377%
24699019654.5

push

github

web-flow
Fix use of generic target in runtime package dependencies (Cherry-pick of #23248) (#23276)

## What

Fixes the following setup:

```py
# BUILD
pex_binary(name='bin_a', entry_point='main_a.py')
pex_binary(name='bin_b', entry_point='main_b.py')
target(name='all_bins', dependencies=[':bin_a', ':bin_b'])
python_test(name="tests", runtime_package_dependencies=[":all_bins"])
```

Previously the PEX dependencies would not get packaged and materialized
when the tests were run.

## Why

Allows a `target()` alias to be used in `runtime_package_dependencies`
to group packageable targets, rather than having to list each one
individually. This would help simplify a setup I have where I have the
misfortune of having to write a loop to generate a list of targets:

```py
# BUILD
for model in models:
  docker_image(name=model.name)

target(name="models", dependencies=[model.name for model in models])
```

Using the generic target I can isolate this mess to the one relevant
directory and keep the rest of the codebase clear.

## Test plan

- [x] New test added to cover the scenario

## Open questions

- Is this the kind of thing we would add to the release notes? Or is it
a bit niche?
- Is this the most reliable way to implement this? I was surprised to
find that generic target isn't modeled as a `TargetGenerator` would that
be a more robust fix? (sounds like it would be a much more invasive
change)
- I _think_ this issue affects the `archive` target too. Shall I
investigate that in this PR? Or keep it small and investigate
separately?

Co-authored-by: Ryan Loader <talk@ryanloader.me>

31666 of 60460 relevant lines covered (52.38%)

0.52 hits per line

Source Files on job test_python_macos14_arm64 - 24699019654.5
  • Tree
  • List 1173
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 24699019654
  • cfdb845d on github
  • Prev Job for on 2.32.x (#24485513205.2)
  • Next Job for on 2.32.x (#25262272470.11)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc