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

pantsbuild / pants / 26660759349

29 May 2026 08:33PM UTC coverage: 92.792%. Remained the same
26660759349

push

github

web-flow
Move Buf subsystem out of the lint subpackage (#23382)

## Summary

Hoists `subsystem.py` and `skip_field.py` from
`src/python/pants/backend/codegen/protobuf/lint/buf/` up to
`src/python/pants/backend/codegen/protobuf/buf/` so non-lint consumers
can depend on the `BufSubsystem` without reaching into the lint package.

Pure file relocation — `git mv` of two files plus import-path updates in
the three files that referenced them. No behavior change.

This is split out from #23343 (which adds Buf as an alternate Python
protobuf code generator) to make that PR easier to review by separating
the mechanical move from the substantive new code. Once this lands,
#23343 will be rebased onto it and reduce to just the codegen feature.

## Test plan

- [ ] `./pants test
src/python/pants/backend/codegen/protobuf/lint/buf::` still passes
(lint/format rules import from new path).
- [ ] CI passes.

4 of 6 new or added lines in 3 files covered. (66.67%)

93069 of 100299 relevant lines covered (92.79%)

4.02 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/python/pants/backend/codegen/protobuf/lint/buf/register.py
1
# Copyright 2022 Pants project contributors (see CONTRIBUTORS.md).
2
# Licensed under the Apache License, Version 2.0 (see LICENSE).
3

NEW
4
from pants.backend.codegen.protobuf.buf import skip_field
×
NEW
5
from pants.backend.codegen.protobuf.buf.subsystem import BufSubsystem
×
6
from pants.backend.codegen.protobuf.lint.buf.format_rules import rules as buf_format_rules
×
7
from pants.backend.codegen.protobuf.lint.buf.lint_rules import rules as buf_lint_rules
×
8
from pants.core.goals.resolves import ExportableTool
×
9
from pants.engine.unions import UnionRule
×
10

11

12
def rules():
×
13
    return (
×
14
        *buf_format_rules(),
15
        *buf_lint_rules(),
16
        *skip_field.rules(),
17
        UnionRule(ExportableTool, BufSubsystem),
18
    )
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