From 2b021fe1b29d174eed437516d2f1ca008ad3fd7a Mon Sep 17 00:00:00 2001 From: "Samuel EF. Tinnerholm" Date: Fri, 19 Jun 2026 07:45:38 +0200 Subject: [PATCH] fix(hyperliquid): default fetchOHLCV params to {} so server dispatch survives Server's flat-body dispatch passes a single merged object as args[0], leaving args[1] undefined. The other HL read methods make params optional; OHLCV did not, so calls without explicit start/end crashed with 'Cannot read properties of undefined (reading start)'. Reproduces via MCP: pmxt.fetchOHLCV({exchange:'hyperliquid', outcomeId:'hl-outcome-172', resolution:'1h'}). --- core/src/exchanges/hyperliquid/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/exchanges/hyperliquid/index.ts b/core/src/exchanges/hyperliquid/index.ts index 29b3fc0f..62fcc36f 100644 --- a/core/src/exchanges/hyperliquid/index.ts +++ b/core/src/exchanges/hyperliquid/index.ts @@ -145,7 +145,7 @@ export class HyperliquidExchange extends PredictionMarketExchange { return this.normalizer.normalizeOrderBook(raw, outcomeId); } - async fetchOHLCV(outcomeId: string, params: OHLCVParams): Promise { + async fetchOHLCV(outcomeId: string, params: OHLCVParams = {}): Promise { const raw = await this.fetcher.fetchRawOHLCV(outcomeId, params); return this.normalizer.normalizeOHLCV(raw, params); }