Fix linting and type errors for CI

- Use X | None syntax instead of Optional[X] (UP045)
- Sort imports in dashboard app (I001)
- Remove unnecessary UTF-8 encoding argument (UP012)
- Add 'from err' to exception re-raises (B904)
- Remove unused imports in integration tests (F401)
- Fix useless expression in test (B018)
- Cast **1.5 result to float in LDO model (mypy no-any-return)
- Use functools.partial instead of lambda in server (mypy misc)
This commit is contained in:
2025-06-12 22:05:46 +00:00
parent cfe8dab7a8
commit e38f514153
8 changed files with 14 additions and 15 deletions

View File

@@ -1,6 +1,6 @@
"""Command-line interface for py_dvt_ate."""
from typing import Annotated, Optional
from typing import Annotated
import typer
@@ -23,7 +23,7 @@ def version_callback(value: bool) -> None:
@app.callback()
def main(
version: Annotated[
Optional[bool],
bool | None,
typer.Option(
"--version",
"-v",

View File

@@ -12,7 +12,6 @@ import streamlit as st
from py_dvt_ate.simulation.physics.engine import PhysicsEngine
# History buffer size for charts
HISTORY_SIZE = 500