Skip to content

Fox v2 scheduler fixes#4190

Merged
springfall2008 merged 2 commits into
mainfrom
fix/fox_v2
Jul 5, 2026
Merged

Fox v2 scheduler fixes#4190
springfall2008 merged 2 commits into
mainfrom
fix/fox_v2

Conversation

@springfall2008

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings July 5, 2026 19:35

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Fox v2/v3 scheduler and settings handling so “unsupported setting” errors are treated as permanent per-device, with safe defaults applied where appropriate, and so schedule-derived limits are preserved across v3 scheduler writes. It also expands Fox API test coverage for these scenarios and bumps Predbat’s version.

Changes:

  • Track and persist per-device “unsupported setting” keys (errno 42015/44096), stop polling/writing them, and apply safe defaults (notably WorkMode as a select).
  • Derive certain device settings from scheduler reads (e.g., Export/Import/PV limits, MaxSoc, MinSocOnGrid) and carry stored limits into v3 scheduler writes.
  • Add regression tests for unsupported settings, scheduler-derived settings, and request errno handling; update CSpell dictionary; bump version.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
apps/predbat/fox.py Adds unsupported-setting tracking/defaults, derives settings from schedules, and carries limits into v3 scheduler writes.
apps/predbat/tests/test_fox_api.py Adds tests covering unsupported settings behavior, scheduler-derived settings, and unsupported errno propagation.
apps/predbat/predbat.py Bumps THIS_VERSION to v8.44.2.
.cspell/custom-dictionary-workspace.txt Adds Fox-related terms for spell-checking.

Comment thread apps/predbat/fox.py Outdated
Comment thread apps/predbat/fox.py
Comment on lines +1165 to +1168
for group_key, setting_key in SCHEDULE_DERIVED_LIMITS:
value = self.device_settings.get(deviceSN, {}).get(setting_key, {}).get("value")
if value is not None:
extra_param[group_key] = value
Comment thread apps/predbat/fox.py
Comment thread apps/predbat/fox.py
@springfall2008 springfall2008 merged commit 9d6a752 into main Jul 5, 2026
2 checks passed
@springfall2008 springfall2008 deleted the fix/fox_v2 branch July 5, 2026 19:43
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.

2 participants