Skip to content

Verify contract source-code lookup#25

Open
crossagent-production-app[bot] wants to merge 1 commit into
crossagentfrom
worktree/task_3c6007ce0ac94bb9
Open

Verify contract source-code lookup#25
crossagent-production-app[bot] wants to merge 1 commit into
crossagentfrom
worktree/task_3c6007ce0ac94bb9

Conversation

@crossagent-production-app
Copy link
Copy Markdown
Contributor

Addresses #24

Summary

  • Added verified_source filtering to /api/plugin/evm/contracts so the explorer can list contracts that are verified and have stored source code.
  • Added contract UI states that make missing uploaded source explicit and expose a "Verified source only" list filter.

Verification

  • go test ./plugins/evm/http
  • npx prettier --check src/components/contract/contractTable.tsx src/components/contract/info.tsx 'src/pages/contract/[id].tsx'
  • node - <<'NODE' ... require('playwright') ... NODE against http://localhost:3000, mocked contract APIs, and captured /tmp/subscan-contract-source-final.png

Delivery Evidence Summary

Change:

  • Contracts API accepts verified_source: true and returns only contracts where verify_status = "verified" and source_code is present.
  • Contract list UI can filter to verified source-backed rows, and unverified detail pages say source code has not been uploaded.

Objective Evidence:

  • Backend HTTP package tests pass: go test ./plugins/evm/http.
  • Changed contract TSX files pass Prettier check.
  • Playwright browser validation passes against the final UI state with mocked contract data.

Visual Evidence:

  • Visual evidence will be attached immediately after PR creation through gh attach and this body will be updated with the rendered image.

Reviewer:

Risks / Not Covered:

  • go test ./plugins/evm/dao is still blocked locally by the existing plugins/evm/dao/storage_test.go MySQL/config bootstrap requirement.
  • npm run build compiles, then fails on existing static prerender routes with NextRouter was not mounted; the contract flow was validated through next dev plus Playwright.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
subscan-essentials Ready Ready Preview, Comment May 22, 2026 10:11am
subscan-essentials-ui-react Ready Ready Preview, Comment May 22, 2026 10:11am

Request Review

@crossagent-production-app
Copy link
Copy Markdown
Contributor Author

crossagent-production-app Bot commented May 22, 2026

Superseded attachment removed from PR evidence review scope. Formal Delivery Evidence is published in the CrossAgent delivery evidence comment.

@crossagent-production-app
Copy link
Copy Markdown
Contributor Author

crossagent-production-app Bot commented May 22, 2026

Delivery Evidence Summary

Change:

  • PR Verify contract source-code lookup #25 adds verified-source filtering for the EVM contract list and clearer contract-detail source-code states for Heima Explorer.
  • The browser evidence now shows the complete contract source workflow: the verified-source list filter, a source-backed contract detail page, and the reported contract route empty-source state.

Objective Evidence:

  • cd ui-react && SCREENSHOT_PATH=/tmp/pr25-e2e-clean-contract-source.png npx playwright test tmp/evidence/contract-source-e2e.spec.js --reporter=list exit code 0: Playwright launched the local Heima Explorer product app, exercised the verified-source contract list filter, opened a source-backed contract detail fixture, rendered Contract Information, Contract ABI, Contract Source Code, and Contract Byte Code, then checked the reported contract route in the browser. Result: 1 test passed.
  • curl --max-time 30 -sS -I -L https://raw.githubusercontent.com/litentry/subscan-essentials/crossagent-evidence/.crossagent/evidence-images/github-litentry-subscan-essentials-24/1779825990000-heima-contract-source-ui-evidence-composite.png exit code 0: The public Delivery Evidence image URL returns HTTP 200 with content-type image/png and is suitable for inline Markdown rendering in the PR conversation.

Visual Evidence:

  • Heima Explorer contract source-code workflow with verified list, source-backed detail, and reported route state
  • Source Screenshot Match: same product surface as the source issue screenshot: Heima Explorer contract detail page, route /contract/0x63c4545ac01c77cc74044f25b8edea3880224577, Contract tab. Visible source-screenshot anchors matched in the image include Heima Explorer header, Contract #0x63c4545ac01c77cc74044f25b8edea3880224577 page title, Contract Name, Creator, Create At, Balance 1 HEI, Contract tab, Source code has not been uploaded for this contract, Compiler Type, Solidity Standard-JSON-Input, Solidity Single file, Contract Name Optional, Include nightly builds, Compiler Version, Resolc Version, Upload the Standard-Input-JSON (*.json) File, Verify & Publish, and Reset.
  • The same composite image also proves the positive source-code display path on the real Heima Explorer browser surface: EVM Contracts, Verified source only, verified HeimaToken row, Contract Information, Contract ABI, Contract Source Code, and Contract Byte Code.

Reviewer:

Risks / Not Covered:

  • Scope is limited to the Heima Explorer contract source-code lookup and display workflow requested by GitHub Verify contract source-code lookup on Heima test explorer #24.
  • The live test-explorer.heima.network contract route requires Vercel SSO in this environment; local Heima Explorer product UI with API fixtures provides the browser proof.
  • Issue-comment database evidence reports zero source-backed Heima contract rows, so the positive source-code render path is covered with a source-backed API fixture in the real local product UI.

Generated at: 2026-05-26T00:00:11Z

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant