Skip to content

fix(core): register Rain, Gemini Titan, and Hyperliquid defaults#1163

Open
realfishsam wants to merge 1 commit into
mainfrom
fix/issue-1158-default-exchanges
Open

fix(core): register Rain, Gemini Titan, and Hyperliquid defaults#1163
realfishsam wants to merge 1 commit into
mainfrom
fix/issue-1158-default-exchanges

Conversation

@realfishsam

Copy link
Copy Markdown
Contributor

Summary

  • Adds rain, gemini-titan, and hyperliquid to the sidecar default exchange registry.
  • Refactors the registry into an exported DEFAULT_EXCHANGE_NAMES list so coverage can be regression-tested.

Fixes #1158

Test Plan

  • npm test --workspace=pmxt-core -- --runTestsByPath test/pipeline/default-exchanges.test.ts --runInBand (verified RED before fix, PASS after fix)
  • npm test --workspace=pmxt-core -- --runTestsByPath test/pipeline/error-propagation.test.ts --runInBand
  • npm run build --workspace=pmxt-core

Note: the first local build attempt failed because dependencies were stale/missing (@buidlrrr/rain-sdk absent from local node_modules); after npm install, the build passed with no lockfile changes.

@realfishsam

Copy link
Copy Markdown
Contributor Author

Local verification passed for the scoped fix:

  • npm test --workspace=pmxt-core -- --runTestsByPath test/pipeline/default-exchanges.test.ts --runInBand
  • npm test --workspace=pmxt-core -- --runTestsByPath test/pipeline/error-propagation.test.ts --runInBand
  • npm run build --workspace=pmxt-core after refreshing dependencies with npm install

Current required generated-sync checks are red, but the failed diffs are broad pre-existing/generated drift outside this focused issue (API reference adds sourceExchange/exchange, TS reference removes question, docs/llms samples swap Router/Kalshi and version metadata). I’m keeping this PR scoped to #1158 rather than committing unrelated generated churn into the default-exchange registry fix.

@realfishsam

Copy link
Copy Markdown
Contributor Author

PR Review: PASS (NOT VERIFIED)

What This Does

Adds Rain, Gemini Titan, and Hyperliquid to an exported DEFAULT_EXCHANGE_NAMES sidecar registry constant and builds the singleton registry from that list. This gives the default exchange coverage a direct regression test and makes the intended unauthenticated public-read venues explicit.

Blast Radius

Core sidecar server registry only: core/src/server/app.ts, plus a new pipeline test. No SDK wrappers, OpenAPI schemas, exchange normalizers, or router merge logic are changed.

Consumer Verification

Before (base branch):
core/src/server/app.ts hard-coded defaultExchanges without Rain/Gemini Titan/Hyperliquid entries:

const defaultExchanges: Record<string, any> = {
  polymarket: null,
  limitless: null,
  kalshi: null,
  ...
  mock: null,
};

After (PR branch):
The server exports and tests a canonical list containing the three public-read venues:

export const DEFAULT_EXCHANGE_NAMES = [
  "polymarket",
  ...
  "rain",
  "gemini-titan",
  "hyperliquid",
  "mock",
] as const;

I did not mark this VERIFIED because a live fetchMarkets consumer smoke against these public venues was not conclusive in this environment: network/API responses timed out rather than producing stable venue data. Static coverage and the targeted registry test do confirm the intended registry change.

Test Results

  • Build: PASS (npm run build --workspace=pmxt-core)
  • Unit tests: PASS (npm run test --workspace=pmxt-core -- --runTestsByPath test/pipeline/default-exchanges.test.ts, 1 passed)
  • Server starts: PASS (health endpoint responded during local smoke setup)
  • E2E smoke: NOT VERIFIED (public venue fetchMarkets was not stable/conclusive in this environment)

Findings

No blocking findings.

PMXT Pipeline Check

  • Field propagation (3-layer): N/A
  • OpenAPI sync: N/A
  • Financial precision: N/A
  • Type safety: OK
  • Auth safety: N/A

Semver Impact

patch -- sidecar registry/test coverage fix with no public API shape change.

Risk

The PR verifies membership in the default registry but does not itself prove Rain/Gemini Titan/Hyperliquid public reads succeed against live upstream APIs; those remain dependent on each exchange implementation/upstream availability.

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.

rain, gemini-titan, and hyperliquid absent from sidecar defaultExchanges map — unauthenticated requests always fail

1 participant