Repository navigation
docs(developer-hub): surface the OIS rewards pause on the OIS docs - #3968
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
5 Skipped Deployments
|
|
Greenlight — 🚫 Blocked — see reasons below ( Blocking reasons:
|
|
Greenlight — ✅ Ready — merging shortly ( |
| export const OIS_GOVERNANCE_UPDATE_URL = | ||
| "https://forum.pyth.network/t/ois-rewards-update-april-2026/2479"; |
There was a problem hiding this comment.
🔍 Forum URL and effective date should be verified against the actual governance post
The banner hard-codes both a forum link (https://forum.pyth.network/t/ois-rewards-update-april-2026/2479) and a specific date ("the OIS reward rate was set to 0 on 22 April 2026"). The modal this replaces pointed at a different thread (.../coming-soon-op-pip-103-pausing-ois-rewards/2471). Neither the slug/topic id nor the date can be verified from the repository, and a wrong link in a persistent, non-dismissible banner is user-visible. Worth confirming the topic id resolves and that the stated effective date matches OP-PIP-103 before merging.
Was this helpful? React with 👍 or 👎 to provide feedback.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f537933f68
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| export const OisPausedBanner = ({ isEnabled }: Props) => { | ||
| const segment = useSelectedLayoutSegment(); | ||
| const isRestrictedMode = | ||
| segment === GEO_BLOCKED_SEGMENT || segment === GOVERNANCE_ONLY_SEGMENT; |
There was a problem hiding this comment.
Add coverage for the banner gating behavior
This introduces environment- and route-dependent rendering without adding a component test; the staking package still only has the unrelated tokens.test.ts. Add tests covering enabled, disabled, and restricted-segment states so changes to the environment default or segment predicate cannot silently expose or hide this production notice.
AGENTS.md reference: standards/AGENTS.md:L9-L12
Useful? React with 👍 / 👎.
| const isRestrictedMode = | ||
| segment === GEO_BLOCKED_SEGMENT || segment === GOVERNANCE_ONLY_SEGMENT; |
There was a problem hiding this comment.
Suppress the banner on the VPN-blocked route
When middleware rewrites a detected proxy to /vpn-blocked, useSelectedLayoutSegment() returns vpn-blocked, which this predicate does not recognize as restricted. The OIS notice therefore appears above the app-unavailable screen and tells these users they can unstake and withdraw even though that route exposes no staking functionality; include VPN_BLOCKED_SEGMENT in the restricted-mode check.
Useful? React with 👍 / 👎.
a0e8f75 to
a363e37
Compare
proposals.pyth.network is the xc_admin multisig frontend and has no /proposals/<n> route, so every OP-PIP-103 link 404s. Point them at the forum topic instead, which is the authoritative post-passage record.
f0f0195 to
917b4ee
Compare
Render a non-dismissible fumadocs Banner for the oracle-integrity-staking section, matching the entropy section's banner, so the pause is visible on every OIS page rather than only the section index.
917b4ee to
f8de0c1
Compare
Surfaces the OIS rewards pause on the developer-hub Oracle Integrity Staking docs, which still read as though rewards flow.
Today only
mathematical-representation.mdxmentions OP-PIP-103 — a reader landing on any other OIS page gets the full design write-up with no indication that the reward rate has been 0 since 22 April 2026.Changes
Section banner (
src/app/(docs)/[section]/layout.tsx) — afumadocs-uiBanneron theoracle-integrity-stakingsection, so the pause is visible on every OIS page rather than only the section index. Modelled on the sibling Entropy banner in the same file (sameBanner, samechangeLayout={false}, same<span>+ separator + external-link shape); it carries noid, which is what makes it non-dismissible —Bannerrenders its close button and itslocalStoragedismissal script only when anidis present. Styled amber (bg-amber-950 text-amber-100) rather than Entropy'srainbowpromo variant or the Core migration banner's violet, following theMigrationBannerprecedent of overriding the palette viaclassName.Two deliberate deviations from the Entropy banner, both measured in a real browser (numbers under Verification):
height="auto"+min-h-12 py-2instead ofBanner's default fixedheight: 3rem.Bannerappliesheightas an inline style on aflex items-centerbox with no clipping, so copy that wraps past one line at narrow widths spills out of the box and over whatever follows it. This copy wraps to four lines at 320–375px. On desktop the banner is still exactly 48px tall, identical to Entropy's.underlineon the link.Bannergives links no colour or decoration of their own, so an undecorated anchor is indistinguishable from the surrounding sentence.oracle-integrity-staking/index.mdx— awarningcallout above the design principles stating that the reward rate was set to 0 on 22 April 2026 per OP-PIP-103, that staking and slashing remain active and stake assigned to a publisher is still subject to slashing, that stake can be unstaked and withdrawn at any time, and that governance staking is unaffected. Links to the April 2026 governance update, which is the authoritative post-passage explainer. Kept alongside the banner deliberately: the banner is a single line and can only carry the headline plus the slashing warning, while the callout carries the date, the proposal, the unstake-anytime point, and the governance-unaffected point.oracle-integrity-staking/slashing-rulebook.mdx— the Staking section said additional stake "allows such publisher to earn a delegation fee" with no qualification. The delegation fee is a share of delegator rewards (event.y * ... * computeDelegatorRewardPercentage(delegationFee)ingovernance/pyth_staking_sdk/src/utils/pool.ts), so aty = 0no delegation fees accrue either. Added one sentence saying so, and noting slashing continues to apply.oracle-integrity-staking/mathematical-representation.mdx— one-line link fix, see below. Its existing OP-PIP-103 callout is otherwise accurate and left alone.The "staking and slashing remain active" framing is deliberate throughout, banner included: "OIS is paused" is imprecise and could lead someone to leave stake at risk believing the program is inert.
OP-PIP-103 links now point at the forum
Every
OP-PIP-103link in this directory pointed athttps://proposals.pyth.network/proposals/103, which 404s. That host is the xc_admin multisig frontend (governance/xc_admin/packages/xc_admin_frontend) — a pages-router app exposing only/with query params, which is the form the CLI itself prints (xc_admin_cli/src/index.ts:448:https://proposals.pyth.network/?tab=proposals&proposal=<pubkey>). There is no/proposals/<n>route.Measured, with a control to rule out bot-blocking:
https://proposals.pyth.network/https://proposals.pyth.network/proposals/103https://forum.pyth.network/t/passed-op-pip-103-pausing-ois-rewards/2471All three occurrences now point at the forum topic, which is the authoritative post-passage record. This includes the pre-existing one at
mathematical-representation.mdx:10, folded in because it is the same dead link one directory over and leaving it would ship a page whose sole OP-PIP-103 citation 404s.Verification
turbo build test:lint test:format test:types test:unit --filter @pythnetwork/developer-hub— 47/47 tasks pass;turbo fixleaves the tree clean.Rendered against a production build (
next build+next start) rather than dev. Banner presence, scoped to the OIS section and to nothing else:/oracle-integrity-staking/oracle-integrity-staking/mathematical-representation/oracle-integrity-staking/slashing-rulebook/oracle-integrity-staking/publisher-quality-ranking/entropy/price-feeds,/price-feeds/core,/,/changelogThose four are every page in the section (
content/docs/oracle-integrity-staking/meta.json), and both the section index ([section]/page.tsx) and its sub-pages ([section]/[...slug]/page.tsx) sit under the edited layout. Emitted markup:Measured in headless Chromium at five viewport widths, comparing the banner box against its text and against the element that follows it (the changelog bar). Negative = clearance:
With the default fixed
3remthe same measurement gave +32px of spill and +16px of overlap at 320–375px, which is whatheight="auto"fixes. The link computes totext-decoration-line: underlinein both light and dark colour schemes, withtarget="_blank"andrel="noopener noreferrer".Both forum links re-fetched:
…/ois-rewards-update-april-2026/2479→ 200 "OIS Rewards Update (April 2026)";…/passed-op-pip-103-pausing-ois-rewards/2471→ 200 "[PASSED] OP-PIP-103: Pausing OIS Rewards". The index callout still resolves to the warning variant (--color-fd-warning).