-
-
Notifications
You must be signed in to change notification settings - Fork 120
Exclude 'BOOST' from low rate condition checks #3706
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -2375,7 +2375,7 @@ def load_octopus_slots(self, car_n, octopus_slots, octopus_intelligent_consider_ | |||||
| new_slot["end"] = end_minutes | ||||||
| new_slot["kwh"] = kwh | ||||||
| new_slot["average"] = self.rate_import.get(start_minutes, self.rate_min) | ||||||
| if octopus_slot_low_rate and source != "bump-charge": | ||||||
| if octopus_slot_low_rate and source != "bump-charge" and source != "BOOST": | ||||||
| new_slot["average"] = self.rate_min # Assume price in min | ||||||
| new_slot["cost"] = dp2(new_slot["average"] * kwh) | ||||||
|
Comment on lines
2377
to
2380
|
||||||
| new_slot["soc"] = dp2(car_soc) | ||||||
|
|
@@ -2387,7 +2387,7 @@ def load_octopus_slots(self, car_n, octopus_slots, octopus_intelligent_consider_ | |||||
| new_slot["end"] = end_minutes_original | ||||||
| new_slot["kwh"] = 0.0 | ||||||
| new_slot["average"] = self.rate_import.get(start_minutes, self.rate_min) | ||||||
| if octopus_slot_low_rate and source != "bump-charge": | ||||||
| if octopus_slot_low_rate and source != "bump-charge" and source != "BOOST": | ||||||
| new_slot["average"] = self.rate_min # Assume price in min | ||||||
| new_slot["cost"] = 0.0 | ||||||
| new_slot["soc"] = dp2(car_soc) | ||||||
|
|
@@ -2400,7 +2400,7 @@ def load_octopus_slots(self, car_n, octopus_slots, octopus_intelligent_consider_ | |||||
| new_slot["end"] = end_minutes | ||||||
| new_slot["kwh"] = kwh | ||||||
| new_slot["average"] = self.rate_import.get(start_minutes, self.rate_min) | ||||||
| if octopus_slot_low_rate and source != "bump-charge": | ||||||
| if octopus_slot_low_rate and source != "bump-charge" and source != "BOOST": | ||||||
| new_slot["average"] = self.rate_min # Assume price in min | ||||||
| new_slot["cost"] = dp2(new_slot["average"] * kwh) | ||||||
| new_slot["soc"] = dp2(car_soc) | ||||||
|
|
@@ -2429,7 +2429,7 @@ def rate_add_io_slots(self, car_n, rates, octopus_slots): | |||||
| start_minutes, end_minutes, kwh, source, location = self.decode_octopus_slot(car_n, slot, raw=True) | ||||||
|
|
||||||
| # Ignore bump-charge slots as their cost won't change | ||||||
|
||||||
| # Ignore bump-charge slots as their cost won't change | |
| # Ignore bump-charge and BOOST slots as their cost/handling is fixed and won't change |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change introduces a new special-case dispatch source ("BOOST") affecting both slot pricing display (load_octopus_slots) and rate masking (rate_add_io_slots), but there’s no unit test coverage ensuring BOOST is treated the same way as bump-charge. Please add/update tests (e.g., in apps/predbat/tests/test_octopus_slots.py and/or test_rate_add_io_slots.py) to assert BOOST slots don’t get forced to rate_min and don’t mark minutes as off-peak.