Skip to content

Skip missing temperature adjustment values - #458

Merged
mr-manuel merged 1 commit into
mr-manuel:masterfrom
akmhatey-ai:codex/skip-missing-temperature-adjust-457
May 17, 2026
Merged

Skip missing temperature adjustment values#458
mr-manuel merged 1 commit into
mr-manuel:masterfrom
akmhatey-ai:codex/skip-missing-temperature-adjust-457

Conversation

@akmhatey-ai

Copy link
Copy Markdown
Contributor

Summary

  • Preserve missing temperature sensor values when applying configured temperature adjustments.
  • This prevents startup from crashing when a BMS reports sensors 1/2 but leaves sensor 3/4 or MOS temperature as None.
  • Added a small regression test for the adjustment helper and a changelog entry.

Fixes #457.

Validation

  • uv run --with pytest --with pyserial pytest tests/test_dbushelper_temperature.py -q -> 5 passed
  • uv run --with pytest --with pyserial pytest tests/test_dbushelper_temperature.py tests/test_cached_dbus_proxy.py tests/test_get_bus.py -q -> 36 passed
  • uv run --with pytest --with pyserial pytest --ignore=tests/bms -q -> 54 passed
  • uv run --with black black --check dbus-serialbattery/dbushelper.py tests/test_dbushelper_temperature.py -> passed
  • uv run --with flake8 flake8 dbus-serialbattery/dbushelper.py tests/test_dbushelper_temperature.py -> passed
  • git diff --cached --check -> passed
  • gitleaks protect --staged --redact --verbose -> no leaks found

I also tried uv run --with pytest --with pyserial pytest -q; on Windows it stops during collection because tests/bms/test_lltjbd_up16s.py imports the Unix-only termios module.

@mr-manuel

Copy link
Copy Markdown
Owner

Thanks!

@mr-manuel
mr-manuel merged commit 5842e44 into mr-manuel:master May 17, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

logfile TypeError with temperature

2 participants