nixos-rebuild-ng: fix mypy issues
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
# mypy: disable-error-code=comparison-overlap
|
||||
from typing import Final
|
||||
|
||||
# Build-time flags
|
||||
|
||||
@@ -8,7 +8,7 @@ from typing import Any, ClassVar, Self, TypedDict, override
|
||||
|
||||
from .process import Remote, run_wrapper
|
||||
|
||||
type ImageVariants = list[str]
|
||||
type ImageVariants = dict[str, str]
|
||||
|
||||
|
||||
class NixOSRebuildError(Exception):
|
||||
|
||||
@@ -14,7 +14,7 @@ class LogFormatter(logging.Formatter):
|
||||
}
|
||||
|
||||
@override
|
||||
def format(self, record: logging.LogRecord) -> str:
|
||||
def format(self, record: logging.LogRecord) -> Any:
|
||||
record.levelname = record.levelname.lower()
|
||||
formatter = self.formatters.get(record.levelno, self.formatters["DEFAULT"])
|
||||
return formatter.format(record)
|
||||
|
||||
Reference in New Issue
Block a user