Remove the MCP server and split NordPool today/tomorrow fetch decisions

- Drop the HomeAssistant.McpServer wiring from opencode.json along with the
  Cursor live-validation hook, rule and skill; update AGENTS.md and README
- Rename ShouldFetchNewPrices to ShouldFetchTodaysPrices and add a separate
  ShouldFetchTomorrowPrice that waits until the CET publish hour
  (TomorrowPricesPublishHour)
- Inject TimeProvider into NordPoolPriceService, use the CET zone for the
  current date and record fetch timestamps from it
- Rework the NordPool tests around FakeTimeProvider and cover fetching only
  today before the publish hour
This commit is contained in:
2026-12-01 13:46:19 +02:00
parent f919d6b25b
commit a9f329ffcd
14 changed files with 124 additions and 330 deletions
+1 -1
View File
@@ -217,7 +217,7 @@ public class NordPoolInit
UnitOfMeasurement = UnitOfMeasurement,
DayQuartersIndex = _priceService.DayQuartersIndex,
LastApiUpdateDate = _priceService.LastUpdatedDate,
UsingCachedData = !_priceService.ShouldFetchNewPrices(todayCet),
UsingCachedData = !_priceService.ShouldFetchTodaysPrices(todayCet),
TodayNordPoolPrice = _priceService.TodayNordPoolPrice,
TomorrowNordPoolPrice = _priceService.TomorrowNordPoolPrice,
CheapestIntervals = CheapestIntervals,