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

pantsbuild / pants / 19477274756

18 Nov 2025 06:38PM UTC coverage: 80.291% (+0.001%) from 80.29%
19477274756

Pull #22889

github

web-flow
Merge f14bb9a80 into a217a6c34
Pull Request #22889: Java fix bug with inner class inference

21 of 27 new or added lines in 2 files covered. (77.78%)

267 existing lines in 10 files now uncovered.

78098 of 97269 relevant lines covered (80.29%)

3.36 hits per line

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

95.0
/src/python/pants/backend/python/typecheck/pytype/subsystem.py
1
# Copyright 2022 Pants project contributors (see CONTRIBUTORS.md).
2
# Licensed under the Apache License, Version 2.0 (see LICENSE).
3

4
from __future__ import annotations
3✔
5

6
from pants.backend.python.subsystems.python_tool_base import PythonToolBase
3✔
7
from pants.backend.python.target_types import ConsoleScript
3✔
8
from pants.core.util_rules.config_files import ConfigFilesRequest
3✔
9
from pants.option.option_types import ArgsListOption, FileOption, SkipOption
3✔
10
from pants.util.strutil import help_text, softwrap
3✔
11

12

13
class Pytype(PythonToolBase):
3✔
14
    options_scope = "pytype"
3✔
15
    name = "Pytype"
3✔
16
    help_short = help_text(
3✔
17
        """
18
        The Pytype utility for typechecking Python code
19
        (https://github.com/google/pytype).
20
        """
21
    )
22

23
    default_main = ConsoleScript("pytype")
3✔
24
    default_requirements = ["pytype==2024.9.13"]
3✔
25
    default_version = "pytype@2024.9.13"
3✔
26

27
    register_interpreter_constraints = True
3✔
28

29
    default_lockfile_resource = ("pants.backend.python.typecheck.pytype", "pytype.lock")
3✔
30

31
    skip = SkipOption("check")
3✔
32
    args = ArgsListOption(example="--version")
3✔
33
    config = FileOption(
3✔
34
        default=None,
35
        help=softwrap(
36
            """
37
            Path to an toml config file understood by Pytype
38
            (https://github.com/google/pytype#config-file).
39
            """
40
        ),
41
    )
42

43
    def config_request(self) -> ConfigFilesRequest:
3✔
44
        """Pytype will look for a  `pyproject.toml` (with a `[tool.pytype]` section) in the project
45
        root.
46

47
        Pytype's configuration content is specified here: https://github.com/google/pytype#config-
48
        file.
49
        """
50

UNCOV
51
        return ConfigFilesRequest(
×
52
            discovery=True,
53
            check_existence=[self.config] if self.config else [],
54
            check_content={"pyproject.toml": b"[tool.pytype"},
55
        )
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