Files
EOS/src/akkudoktoreos/__init__.py
Bobby Noelte 71e5abce88
Some checks failed
Bump Version / Bump Version Workflow (push) Has been cancelled
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (python) (push) Has been cancelled
docker-build / platform-excludes (push) Has been cancelled
pre-commit / pre-commit (push) Has been cancelled
Run Pytest on Pull Request / test (push) Has been cancelled
docker-build / build (push) Has been cancelled
docker-build / merge (push) Has been cancelled
Close stale pull requests/issues / Find Stale issues and PRs (push) Has been cancelled
fix: energy charts bidding zone in request (#948)
Ensure that the bidding zone in the request is correctly set to a
string value (not an enum).

This seems to be also an issue with python version < 3.11. Add safeguards
to only use python >= 3.11. Still keep a regression test for the enum
conversion to string.

Signed-off-by: Bobby Noelte <b0661n0e17e@gmail.com>
2026-03-15 13:32:05 +01:00

12 lines
331 B
Python

import sys
MIN_VERSION = (3, 11)
if sys.version_info < MIN_VERSION:
min_version = ".".join(map(str, MIN_VERSION))
raise RuntimeError(
f"EOS requires Python {min_version} or newer. "
f"Current version: {sys.version.split()[0]}. "
f"Please upgrade your Python installation or Home Assistant."
)