mirror of
https://github.com/XuehaiPan/nvitop.git
synced 2026-05-15 06:06:12 -06:00
chore(pre-commit): update pre-commit hooks
This commit is contained in:
parent
75fc7b4c65
commit
5cc0e40f98
2 changed files with 8 additions and 3 deletions
|
|
@ -29,7 +29,7 @@ repos:
|
|||
args: [--ignore-case]
|
||||
files: ^docs/source/spelling_wordlist\.txt$
|
||||
- repo: https://github.com/astral-sh/ruff-pre-commit
|
||||
rev: v0.14.9
|
||||
rev: v0.14.11
|
||||
hooks:
|
||||
- id: ruff-check
|
||||
args: [--fix, --exit-non-zero-on-fix]
|
||||
|
|
@ -41,7 +41,7 @@ repos:
|
|||
- id: codespell
|
||||
additional_dependencies: [".[toml]"]
|
||||
- repo: https://github.com/pre-commit/mirrors-mypy
|
||||
rev: v1.19.0
|
||||
rev: v1.19.1
|
||||
hooks:
|
||||
- id: mypy
|
||||
exclude: |
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ class DevicePanel(BasePanel): # pylint: disable=too-many-instance-attributes
|
|||
self.formats_full: list[str] = [
|
||||
'│ {physical_index:>3} {name:<19} {persistence_mode:>4} '
|
||||
'│ {bus_id:<16} {display_active:>3} │ {total_volatile_uncorrected_ecc_errors:>20} │',
|
||||
'│ {fan_speed_string:>3} {temperature_string:>4} {performance_state:>4} {power_status:>13} '
|
||||
'│ {fan_speed_string:>3} {temperature_string:>4} {performance_state:^4} {power_status:>13} '
|
||||
'│ {memory_usage:>20} │ {gpu_utilization_string:>7} {compute_mode:>11} │',
|
||||
]
|
||||
|
||||
|
|
@ -122,6 +122,11 @@ class DevicePanel(BasePanel): # pylint: disable=too-many-instance-attributes
|
|||
'{total_volatile_uncorrected_ecc_errors:>20}',
|
||||
'{mig_mode:>8} {total_volatile_uncorrected_ecc_errors:>10}',
|
||||
)
|
||||
if all(len(device.power_status.rpartition(' / ')[-1]) < 5 for device in self.snapshots):
|
||||
self.formats_compact[0] = self.formats_compact[0].replace(
|
||||
'performance_state:<3',
|
||||
'performance_state:>3',
|
||||
)
|
||||
|
||||
@property
|
||||
def width(self) -> int:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue