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

pantsbuild / pants / 19015773527

02 Nov 2025 05:33PM UTC coverage: 17.872% (-62.4%) from 80.3%
19015773527

Pull #22816

github

web-flow
Merge a12d75757 into 6c024e162
Pull Request #22816: Update Pants internal Python to 3.14

4 of 5 new or added lines in 3 files covered. (80.0%)

28452 existing lines in 683 files now uncovered.

9831 of 55007 relevant lines covered (17.87%)

0.18 hits per line

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

0.0
/src/python/pants/bsp/spec/log.py
1
# Copyright 2022 Pants project contributors (see CONTRIBUTORS.md).
2
# Licensed under the Apache License, Version 2.0 (see LICENSE).
UNCOV
3
from __future__ import annotations
×
4

UNCOV
5
from dataclasses import dataclass
×
UNCOV
6
from enum import Enum
×
UNCOV
7
from typing import Any
×
8

UNCOV
9
from pants.bsp.spec.base import TaskId
×
UNCOV
10
from pants.bsp.spec.notification import BSPNotification
×
11

12
# -----------------------------------------------------------------------------------------------
13
# Log message
14
# See https://build-server-protocol.github.io/docs/specification.html#log-message
15
# -----------------------------------------------------------------------------------------------
16

17

UNCOV
18
class MessageType(Enum):
×
19
    # An error message.
UNCOV
20
    ERROR = 1
×
21
    # A warning message.
UNCOV
22
    WARNING = 2
×
23
    # An information message.
UNCOV
24
    INFO = 3
×
25
    # A log message.
UNCOV
26
    LOG = 4
×
27

28

UNCOV
29
@dataclass(frozen=True)
×
UNCOV
30
class LogMessageParams(BSPNotification):
×
UNCOV
31
    notification_name = "build/logMessage"
×
32

33
    # The message type. See {@link MessageType}
UNCOV
34
    type_: MessageType
×
35

36
    # The actual message
UNCOV
37
    message: str
×
38

39
    # The task id if any.
UNCOV
40
    task: TaskId | None = None
×
41

42
    # The request id that originated this notification.
UNCOV
43
    origin_id: str | None = None
×
44

UNCOV
45
    def to_json_dict(self) -> dict[str, Any]:
×
46
        result: dict[str, Any] = {
×
47
            "message": self.message,
48
            "type": self.type_.value,
49
        }
50
        if self.task is not None:
×
51
            result["task"] = self.task.to_json_dict()
×
52
        if self.origin_id is not None:
×
53
            result["originId"] = self.origin_id
×
54
        return result
×
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