chore: remove Pyth + SPYX (retirement tail ended) - #312
Merged
Conversation
The SPYX rollout tail ran on Pyth (validator: Pyth Pro history; miner: Pyth Hermes). Pyth Pro now returns 401 without a key, so the tail path is dead — it scores/fetches nothing, and the live CI test failed on the 401. SPYX stopped being prompted at the 2026-07-23 SP500 switchover; its moving-average window has aged out. Remove SPYX and every Pyth code path. Validator (price_data_provider.py): drop PYTH_PRO_URL, PYTH_SYMBOL_MAP, fetch_data_pyth, _assert_settled, and the PYTH term in assert_assets_supported; the routing else now raises ValueError for an asset in neither venue map (the Binance/Hyperliquid settlement-witness guards are untouched). competition_config.py: drop SPYX from COM_EQU_24H. moving_average.py: drop the SPYX coefficient. Miner (price_simulation.py): drop TOKEN_MAP, the Hermes URL and _fetch_price_hermes; get_asset_price raises ValueError for an unmapped asset. simulations.py: drop the SPYX sigma (SP500 keeps its own). Tests: remove the Pyth _assert_settled tests, the Pyth-tail class, and the skipped live SPYX test; add unsupported-asset raise tests for both the validator and miner paths. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Removes the final SPYX/Pyth “retirement tail” by deleting the remaining Pyth/Hermes fetch paths and making unsupported assets fail fast, aligning the validator and reference miner with the post-SP500 switchover.
Changes:
- Validator: remove Pyth Pro history path and make unknown assets raise
ValueErrorinstead of falling through. - Miner: remove Pyth Hermes spot-price path and make unknown assets raise
ValueError. - Config/tests: remove SPYX coefficients/config entries and replace Pyth-tail tests with unsupported-asset raise tests.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
synth/validator/price_data_provider.py |
Deletes Pyth code paths and changes the “unknown asset” route to a hard ValueError. |
synth/validator/moving_average.py |
Removes the SPYX moving-average coefficient (SP500 remains). |
synth/validator/competition_config.py |
Removes SPYX from the Commodities/Equities 24h competition asset list. |
synth/miner/price_simulation.py |
Deletes Hermes/TOKEN_MAP path and raises ValueError for unsupported assets. |
synth/miner/simulations.py |
Removes SPYX sigma and clarifies SP500 inherits the former SPYX sigma. |
tests/test_price_data_provider.py |
Removes Pyth-tail tests and adds unsupported-asset raise coverage for validator fetch_data. |
tests/test_miner_price_simulation.py |
Removes Hermes-path test and adds unsupported-asset raise coverage for miner get_asset_price. |
Comments suppressed due to low confidence (1)
synth/miner/price_simulation.py:90
- After removing the last Pyth/Hermes code path here, the repository documentation is now stale: CHANGELOG.md still says "Hermes remains only to serve SPYX prompts". Please update/remove that statement (and any similar docs) so it matches the new behavior.
raise ValueError(f"unsupported asset {asset}")
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Final step of the Pyth exit: delete SPYX and every remaining Pyth code path from synth-subnet.
Why now
SPYX ran its retirement tail on Pyth — validator via Pyth Pro history, miner via Pyth Hermes. Pyth Pro history now returns 401 without a key, so that path is dead: it scores/fetches nothing, and the live CI test (
test_live_history_spyx_pyth_tail) failed on the 401 (skipped in a prior PR). SPYX stopped being prompted at the 2026-07-23 SP500 switchover and itswindow_days=10moving-average scores have aged out. The plan pre-authorized ending the tail here ("if Pyth paywalls mid-tail… accept the loss").Changes
Validator
price_data_provider.py— removePYTH_PRO_URL,PYTH_SYMBOL_MAP,fetch_data_pyth,_assert_settled, and the Pyth term inassert_assets_supported. The routingelsenow raisesValueErrorfor an asset in neither venue map (fail-fast instead of a dead Pyth call). The Binance/Hyperliquid settlement-witness guards are independent and untouched.competition_config.py— dropSPYXfromCOM_EQU_24H.moving_average.py— drop theSPYXcoefficient (SP500 keeps its own).Miner
price_simulation.py— removeTOKEN_MAP, the Hermes URL, and_fetch_price_hermes;get_asset_priceraisesValueErrorfor an unmapped asset.simulations.py— drop theSPYXsigma.Tests
_assert_settledtests, theTestPriceDataProviderPythTailclass, and the skipped live SPYX test.fetch_data) and miner (get_asset_price) paths.Verification
black+flake8clean (pre-commit passed); 24 unit tests pass (live/network tests excluded).Follow-ups (not in this PR)
🤖 Generated with Claude Code