Tighten mainnet PMM bootstrap verification
All checks were successful
Deploy to Phoenix / deploy (push) Successful in 9s

This commit is contained in:
defiQUG
2026-04-14 17:27:39 -07:00
parent cba978f656
commit 6ae8590134
2 changed files with 43 additions and 4 deletions

View File

@@ -44,6 +44,11 @@ It is intentionally split into:
- Re-run result after the fix:
- `cWUSDT/cWUSDC` now resolves and reads healthy reserves
- readiness gate now ends with `4 hard failure(s), 0 warning(s)`
- `2026-04-14` `check-mainnet-public-dodo-cw-bootstrap-pools.sh` now passes after
downgrading operator-wallet balance shortages from false failures to warnings.
- Same bootstrap verifier surfaced one env/registry drift:
- registry-authoritative `cWUSDC/USDC` pool is `0x69776fc607e9edA8042e320e7e43f54d06c68f0E`
- some env/default flows still reference legacy pool `0xB227dDA4e89E2EA63A1345509C9AC02644e8d526`
This means Mainnet public PMM operation is not yet in a fully healthy state even
though large parts of the deployment inventory exist.
@@ -146,6 +151,7 @@ though large parts of the deployment inventory exist.
- rebalance `cWUSDC/USDC`
- rebalance `cWUSDT/USDT`
- rebalance `cWUSDC/USDT`
- reconcile remaining legacy `POOL_CWUSDC_USDC_MAINNET` env/default references with the registry-authoritative pool
6. Publish the final ALL Mainnet native venue matrix before trying to wire full MEV discovery there.
## Truthful Completion Condition

View File

@@ -53,6 +53,7 @@ pairs=(
)
failures=0
warnings=0
echo "=== Mainnet Public DODO cW Bootstrap Pools ==="
echo "Integration: $INTEGRATION"
@@ -92,13 +93,40 @@ for row in "${pairs[@]}"; do
continue
fi
dry_run_output="$(
dry_run_output=""
dry_run_status=0
if ! dry_run_output="$(
bash "${REPO_ROOT}/scripts/deployment/run-mainnet-public-dodo-cw-swap.sh" \
--pair="$pair" \
--direction="$direction" \
--amount="$amount" \
--dry-run
)"
--dry-run 2>&1
)"; then
dry_run_status=$?
fi
if (( dry_run_status != 0 )); then
if grep -q 'insufficient input-token balance' <<<"$dry_run_output"; then
echo "- $pair"
echo " pool=$pool"
if [[ -n "$configured_pool" && "${configured_pool,,}" != "${pool,,}" ]]; then
echo " note=env_pool_overridden_by_registry"
echo " configuredPool=$configured_pool"
fi
echo " mappedPool=$mapped_pool"
echo " reserves=$base_reserve/$quote_reserve"
echo " dryRunDirection=$direction"
echo " dryRunAmount=$amount"
echo " warning=operator_wallet_lacks_input_balance_for_dry_run"
warnings=$((warnings + 1))
continue
fi
echo "[fail] $pair dry-run quote failed" >&2
printf '%s\n' "$dry_run_output" >&2
failures=$((failures + 1))
continue
fi
quote_source="$(printf '%s\n' "$dry_run_output" | awk -F= '/^quoteSource=/ {print $2}')"
estimated_out="$(printf '%s\n' "$dry_run_output" | awk -F= '/^estimatedOut=/ {print $2}')"
@@ -121,9 +149,14 @@ done
if (( failures > 0 )); then
echo
echo "[WARN] Bootstrap pool verification found $failures issue(s)." >&2
echo "[WARN] Bootstrap pool verification found $failures issue(s) and $warnings warning(s)." >&2
exit 1
fi
echo
if (( warnings > 0 )); then
echo "Result: all 11 recorded Mainnet public DODO cW bootstrap pools are mapped and funded; $warnings dry-run check(s) were skipped because the operator wallet lacked the input token."
exit 0
fi
echo "Result: all 11 recorded Mainnet public DODO cW bootstrap pools are mapped, funded, and dry-run routable."