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

pantsbuild / pants / 19197356939 / 10
80%
main: 80%

Build:
DEFAULT BRANCH: main
Ran 08 Nov 2025 08:02PM UTC
Files 1180
Run time 38s
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

08 Nov 2025 07:08PM UTC coverage: 45.421%. Remained the same
19197356939.10

push

github

web-flow
[pants-ng] Initial implementation of contextual config (#22862)

The idea is that instead of global config there can be lots of 
local config files that apply to the directories below them.
The config to apply to a target or file is the union of the config
in its dir, then the config in its parent, and so on up to the
global config in the buildroot. The usual rules for overriding
or merging values across multiple config files will apply, with
the more global config having lower precedence than the
more local config.

Then this idea is taken a step further, by allowing further
contextual filtering based on tags in the filename.
For example, `pants_ci.toml` would only apply in ci, 
`pants_macos.toml` would only apply on macos, 
`pants_ci.macos.toml` would only apply on ci on macos, etc.

This can even support things like `pants_python311.toml`
to have different config for different python interpreters
(these contexts would be requested by the user via some 
as-yet-to-be-determined "context" flag).

The overall goal is to get rid of the duplication of concepts in 
BUILD files and in config in the vast majority of cases. Instead
of having a global option that can be overridden in a special
target field, on a case by case bases, we can often just have config
all the way down (literally!), with Pants doing the partitioning and
invoking the same rule multiple times, each with a different
(subsystems, lists of files) pair.

This change only handles discovery of config files. It does not
wire them up to anything. It is unlikely that existing goal 
implementations can be easily changed to use this mechanism,
so it is probably a pants-ng thing.

The existing config parser continues to be used, but its output
is no longer a global singleton.

27052 of 59558 relevant lines covered (45.42%)

0.45 hits per line

Source Files on job test_python_linux_x86_64_8/10 - 19197356939.10
  • Tree
  • List 1180
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 19197356939
  • ae9999b0 on github
  • Prev Job for on main (#19186107394.3)
  • Next Job for on main (#19250292619.8)
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

© 2025 Coveralls, Inc