Merge origin/master (0.20.1) into release/1.0
Brings OPT-36 (#229) and TEST-37 (#231) onto release/1.0, which keeps SAFETY-128 (#228). No textual conflicts. CHANGELOG: the SAFETY-128 entry moved out of the released 0.20.0 section into "Not in a release yet" above ## 0.20.1; the 0.20.0 and 0.20.1 sections are identical to master. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -206,7 +206,8 @@ def measure(c, now, peak_w):
|
||||
|
||||
|
||||
def make(name, now, *, soc=(55.0, 40.0), modes=("solar_first",
|
||||
"solar_first")):
|
||||
"solar_first"),
|
||||
evening=None):
|
||||
"""The controller of scenario `name` at `now` (UTC), its cycle run once."""
|
||||
assert name in SCENARIOS, name
|
||||
opts = dict(BASE)
|
||||
@@ -271,7 +272,10 @@ def make(name, now, *, soc=(55.0, 40.0), modes=("solar_first",
|
||||
members=members, tomorrow=tomorrow)
|
||||
c.solar_fc_why = None
|
||||
if name != "learning":
|
||||
c.house_profile = profile(now)
|
||||
# OPT-36: `evening` (W) makes the dear hours' use larger than
|
||||
# what a Cheap hours battery covers, so Leftover solar still buys.
|
||||
c.house_profile = profile(now) if evening is None \
|
||||
else profile(now, evening=evening)
|
||||
if name in ("owner", "dynamic", "sunny", "periods", "learning",
|
||||
"notomorrow", "cycle"):
|
||||
measure(c, now, 7000.0 if name != "dynamic" else 2500.0)
|
||||
|
||||
Reference in New Issue
Block a user