Skip to content

Octopus intelligent detection fix#4204

Merged
springfall2008 merged 1 commit into
mainfrom
fix/octopus_iog
Jul 8, 2026
Merged

Octopus intelligent detection fix#4204
springfall2008 merged 1 commit into
mainfrom
fix/octopus_iog

Conversation

@springfall2008

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings July 8, 2026 06:46

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

Fixes Octopus “Intelligent” tariff detection so IOG-only tariff codes are treated as intelligent in both device updates and day/night rate window selection, and adds regression coverage for the previous false-negative.

Changes:

  • Introduces a shared OctopusAPI.is_intelligent_go_tariff() helper to classify INTELLI-* and IOG-* tariff codes.
  • Uses the helper in async_update_intelligent_devices() and async_get_day_night_rates() to avoid missing IOG-only tariffs.
  • Adds regression tests covering the helper and the async_update_intelligent_devices() IOG-only case; bumps Predbat version.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
apps/predbat/octopus.py Adds and applies a shared intelligent/IOG tariff detection helper to fix IOG-only detection gaps.
apps/predbat/tests/test_octopus_day_night_rates.py Adds targeted regression tests for the new helper and the IOG-only device-update path.
apps/predbat/predbat.py Bumps THIS_VERSION to v8.44.6 for the release containing the fix.

Comment thread apps/predbat/octopus.py
Comment on lines +1220 to +1228
@staticmethod
def is_intelligent_go_tariff(tariff_code):
"""
Determine whether a tariff code is an Intelligent GO (IOG) tariff.
"""
if not tariff_code:
return False
else:
return ("INTELLI-" in tariff_code) or ("IOG-" in tariff_code)
@springfall2008
springfall2008 merged commit 713545b into main Jul 8, 2026
3 checks passed
@springfall2008
springfall2008 deleted the fix/octopus_iog branch July 8, 2026 06:55
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