Skip to content

Fix coinmetrics-lwba asset-quotes websocket parsing#5184

Closed
cawthorne wants to merge 1 commit into
mainfrom
fix/coinmetrics-lwba-asset-quotes
Closed

Fix coinmetrics-lwba asset-quotes websocket parsing#5184
cawthorne wants to merge 1 commit into
mainfrom
fix/coinmetrics-lwba-asset-quotes

Conversation

@cawthorne

Copy link
Copy Markdown
Contributor

Summary

  • Fix the CoinMetrics LWBA websocket handler to parse asset-quotes responses (asset field) instead of only legacy pair-quotes responses (pair field)
  • Keep backward compatibility for legacy pair messages
  • Update integration fixtures and add unit coverage for frax_frax asset-quotes messages

Context

coinmetrics-lwba subscribes to /v4/timeseries-stream/asset-quotes, but after #3187 the handler still called message.pair.split('-'). Real CoinMetrics responses use asset, so every websocket message failed to parse, cache never updated, and feed uptime could flap as the connection was repeatedly treated as unresponsive.

This affects assets like FRAX when overridden to frax_frax.

Test plan

  • yarn test packages/sources/coinmetrics/test/unit/lwba.test.ts
  • yarn test packages/sources/coinmetrics/test/integration/adapter-ws.test.ts
  • yarn test packages/sources/coinmetrics-lwba/test/integration/adapter-ws.test.ts
  • Deploy to staging and verify FRAX/USD LWBA feed uptime stabilizes
  • Confirm providerIndicatedTimeUnixMs advances continuously on live websocket stream

The LWBA transport switched to asset-quotes in #3187 but still parsed
pair-quotes messages, causing websocket updates to fail and feed uptime
to flap for assets like FRAX.
@changeset-bot

changeset-bot Bot commented Jul 10, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 032fcf1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 6 packages
Name Type
@chainlink/coinmetrics-adapter Patch
@chainlink/coinmetrics-lwba-adapter Patch
@chainlink/token-allocation-adapter Patch
@chainlink/crypto-volatility-index-adapter Patch
@chainlink/savax-price-adapter Patch
@chainlink/xsushi-price-adapter Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@cawthorne cawthorne closed this Jul 10, 2026
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.

1 participant