fix: update oracle tutorial for Pragma's v14 oracle deployment#201
Open
Keinberger wants to merge 1 commit into
Open
fix: update oracle tutorial for Pragma's v14 oracle deployment#201Keinberger wants to merge 1 commit into
Keinberger wants to merge 1 commit into
Conversation
partylikeits1983
approved these changes
May 19, 2026
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.
Overview
This PR updates the "Consuming On-Chain Price Data from the Pragma Oracle"
tutorial so it works against Pragma's v14 oracle. Pragma recently redeployed
their Miden oracle for the v14 protocol, which changed both the deployment
addresses and the consumer-facing interface. The earlier v14 tutorial
migration (#186) only updated the SDK API surface, so the tutorial still
pointed at the dead pre-v14 deployment and failed at runtime.
Changes
oracle_reader.masm) —get_pricecallsget_medianwith thev14 FPI ABI: 16 foreign-procedure inputs carrying the BTC/USD faucet pair
(prefix
1, suffix0), the newget_medianprocedure root, and the neworacle account ID.
oracle_data_query.rs) — publishers are discovered from theoracle's
pragma::oracle::publishersstorage map (the old value-slotheuristic doesn't match the v14 layout), and each publisher's
pragma::publisher::entriesproof is requested keyed by the faucet-pair word.oracle_tutorial.md) — embedded code blocks synced to the runnablefiles; prose, addresses, and example output updated for the v14
[is_tracked, median_price, amount]return layout.Closes #200
Closes #113