Add Chain138 native DODO verification tooling
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
# Chain 138 Native DODO Read Surface Verifier
|
||||
|
||||
This verifier checks the native Chain 138 DODO read surfaces directly on-chain and prints explicit pass/fail output for the canonical pools.
|
||||
|
||||
## What it checks
|
||||
|
||||
- DODO PMM pools:
|
||||
- `getVaultReserve()`
|
||||
- `getPMMStateForCall()`
|
||||
- D3MM pilot pool:
|
||||
- `getTokenReserve(address)`
|
||||
- `querySellTokens(address,address,uint256)`
|
||||
|
||||
Canonical pools:
|
||||
|
||||
- `cUSDT/cUSDC` - `0x9e89bAe009adf128782E19e8341996c596ac40dC`
|
||||
- `cUSDT/USDT` - `0x866Cb44b59303d8dc5f4F9E3E7A8e8b0bf238d66`
|
||||
- `cUSDC/USDC` - `0xc39B7D0F40838cbFb54649d327f49a6DAC964062`
|
||||
- `WETH10/USDT` D3MM pilot - `0x6550a3a59070061a262a893A1D6F3F490afFDBDA`
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
bash scripts/verify/check-chain138-native-dodo-read-surfaces.sh
|
||||
```
|
||||
|
||||
Optional overrides:
|
||||
|
||||
- `RPC_URL_138`
|
||||
- `CHAIN138_RPC_URL`
|
||||
- `CHAIN138_RPC`
|
||||
- `CHAIN138_DODO_PMM_PROBE_AMOUNT`
|
||||
- `CHAIN138_D3_PROBE_SELL_AMOUNT`
|
||||
|
||||
The script exits non-zero if any required native read surface fails or returns an empty / invalid response.
|
||||
|
||||
If the D3MM `querySellTokens(...)` call fails with `Chainlink: Stale Price`, that is a real native read-surface issue on the canonical pilot pool and the verifier will intentionally fail until the upstream oracle path is healthy again.
|
||||
58
docs/04-configuration/GRU_NATIVE_PROTOCOL_ONLY_POLICY.md
Normal file
58
docs/04-configuration/GRU_NATIVE_PROTOCOL_ONLY_POLICY.md
Normal file
@@ -0,0 +1,58 @@
|
||||
# GRU Native Protocol Only Policy
|
||||
|
||||
## Purpose
|
||||
|
||||
This policy makes one rule explicit for GRU public venue coverage, gas-family mirrors, and MEV/public routing claims:
|
||||
|
||||
- A protocol lane counts as `live`, `routingVisible`, or `publicRoutingEnabled` only when it points at a **native, discoverable protocol contract** on the target network.
|
||||
- Placeholder, scaffold, synthetic, or documentation-only addresses must never be represented as live protocol support.
|
||||
|
||||
## Applies To
|
||||
|
||||
- `cross-chain-pmm-lps/config/deployment-status.json`
|
||||
- public protocol coverage docs and status tables
|
||||
- MEV route / venue inventory derived from those surfaces
|
||||
- operator rollout checklists that reference protocol readiness
|
||||
|
||||
## Required Behavior
|
||||
|
||||
### Live lane requirements
|
||||
|
||||
A protocol lane marked live must have all of the following:
|
||||
|
||||
1. A real on-chain address for the native protocol contract family
|
||||
2. Contract discovery or provenance that ties it back to the intended upstream protocol
|
||||
3. Matching route / planner / indexer visibility where the surface claims it is routable
|
||||
|
||||
### Not allowed as live support
|
||||
|
||||
These must not be counted as live protocol coverage:
|
||||
|
||||
- scaffold addresses
|
||||
- synthetic addresses used only for planning
|
||||
- placeholder addresses shaped from chain IDs or protocol markers
|
||||
- inventory rows that exist only to reserve a future slot
|
||||
|
||||
## Current Implication
|
||||
|
||||
If a venue family is still using scaffold addresses, its status must be represented as one of:
|
||||
|
||||
- `planned`
|
||||
- `scaffolded`
|
||||
- `not yet native`
|
||||
- `out of scope`
|
||||
|
||||
but not:
|
||||
|
||||
- `live`
|
||||
- `routingVisible`
|
||||
- `publicRoutingEnabled`
|
||||
|
||||
## Enforcement
|
||||
|
||||
The deployment-status validator now rejects obvious placeholder addresses for:
|
||||
|
||||
- `gasPmmPools[*].poolAddress` when `publicRoutingEnabled=true`
|
||||
- `gasReferenceVenues[*].venueAddress` when `live=true` or `routingVisible=true`
|
||||
|
||||
This is a guardrail, not a full provenance proof. Operator review still needs to confirm the upstream-native protocol family is correct.
|
||||
@@ -76,6 +76,7 @@ This directory contains setup and configuration guides.
|
||||
|
||||
**DEX and aggregators (Chain 138 tokens and routing):**
|
||||
- **[DEX_AND_AGGREGATORS_CHAIN138_EXPLAINER.md](DEX_AND_AGGREGATORS_CHAIN138_EXPLAINER.md)** ⭐⭐⭐ - Using DEX and aggregators with Chain 138 coins/tokens; routing for DEXs; token-aggregation API, DODO PMM, swap–bridge–swap flows.
|
||||
- **[CHAIN138_NATIVE_DODO_READ_SURFACE_VERIFIER.md](CHAIN138_NATIVE_DODO_READ_SURFACE_VERIFIER.md)** — Native DODO PMM / D3MM read-surface verifier for Chain 138 (`getVaultReserve`, `getPMMStateForCall`, `getTokenReserve`, `querySellTokens`)
|
||||
|
||||
**Chain 138 / Wallets (overview first; all repos in ~/projects/):**
|
||||
- **[CHAIN138_WALLET_REPOSITORIES.md](CHAIN138_WALLET_REPOSITORIES.md)** ⭐⭐⭐ - **Canonical layout:** metamask-integration, LedgerLive, app-ethereum, TrustWallet-Integration each in `~/projects/`. All items **Yes / Completed.**
|
||||
|
||||
Reference in New Issue
Block a user