Skip to content

CLI fix: hardcoded Sepolia bond address in claim and status #661

@realproject7

Description

@realproject7

From E2E test #644 / agent-os #326

Bug

`plotlink claim` and `plotlink status` import a hardcoded Sepolia `MCV2_BOND_ADDRESS` instead of resolving the correct address based on chain ID. On mainnet, the calls revert because the contract doesn't exist at the Sepolia address.

Fix

In `packages/cli/src/constants.ts` (or wherever addresses are defined):

  1. Make bond address chain-aware: Sepolia vs mainnet
  2. Read chain ID from config/RPC and select the correct address
  3. Update `claim.ts` and `status.ts` to use the resolved address

Mainnet MCV2_Bond: check `lib/contracts/constants.ts` in the main app for the correct address.

Branch

`task/661-cli-chain-aware-addresses`

Self-Verification (T3)

  • Run `plotlink claim` on Base mainnet — no Sepolia address revert
  • Run `plotlink status --storyline ` on Base mainnet — returns correct data
  • `npm run build` passes

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/T3Assigned to T3 builder agent

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions