Repository navigation
fix(scenarios): follow Pump's deployed programs - IDLs from pump-public-docs and the mayhem fee recipient - #60
Open
92Infinitus92 wants to merge 2 commits into
Conversation
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.
Pump upgrades its programs without writing their on-chain IDLs again, so those copies lag the deployed programs, and the Pump graduation test fails on main. This PR fixes the test and bundles the latest IDLs Pump publishes in pump-public-docs, which the monitoring run now compares Pump with. It is the Pump half of #55, which is split in two, and it carries the Pump fix from #54.
test_pump_token2022_graduation_lifecyclecreates its own Token-2022 coin withcreate_v2and takes the fee recipient fromGlobal, so a mayhem coin pays the reserved recipient. A second test runs the same lifecycle for a mayhem coin.pump/v1/idl.jsonisidl/pump.jsonat pump-public-docs639b87fb45c3(2026-10-13), sha2567616681ea557975f9f623ac211080f22a93060781eaf4765b0a488d980997207.pump-amm/v1/idl.jsonisidl/pump_amm.jsonat8cda1fa30ea6(2026-10-07), sha256b7d8c57a4d9c4dd0109a9ab893052352333252d4eedced10ac091d4d66cab89b. Both are byte for byte; the READMEs record the commits and hashes.virtual_quote_reservesstays onpump-amm-pool-stateandpump-amm-canonical-pool. Its description now says the value is signed and not 0 on every pool (about 130 thousand pools hold a non-zero value), and the price-shock recipe accounts for it: to scale the effective quote reserves by k, write k * (Q + V) - Q.BondingCurveis 166 bytes (115 on main) andPool287 (261 on main). The engine does not write an account shorter than its IDL type; the override is skipped with a log warning and the scenario still plays. On mainnet today about 2.6 million curves (166 and 256 bytes) and 1.33 million pools (287 bytes and more) can be written. Compared with main, at least 11.3 million older curves and 23 thousand pools no longer can.live_accounts_shorter_than_their_idl_type_are_left_unchangeddocuments this on 150-byte curves and on 245 and 271-byte pools.Tests:
cargo +nightly fmt --all -- --checkandcargo clippy -p surfpool-core --all-targetspass.cargo test -p surfpool-core --features ignore_tests_cigives 900 passed, 0 failed. The Pump tests against mainnet (--features integration-tests pump) give 16 passed, 0 failed, andcargo test -p surfpool-mcp the_pump_templates_appearpasses.