Skip to content

feat: implement contract verification script for Etherscan (fixes #165)#288

Merged
Adeswalla merged 2 commits intoAdeswalla:mainfrom
Josetic224:main
Mar 30, 2026
Merged

feat: implement contract verification script for Etherscan (fixes #165)#288
Adeswalla merged 2 commits intoAdeswalla:mainfrom
Josetic224:main

Conversation

@Josetic224
Copy link
Copy Markdown
Contributor

@Josetic224 Josetic224 commented Mar 30, 2026

feat: automated block explorer verification & ABI tracking (fixes #165)

Description
This PR resolves issue #165 by implementing an automated Block Explorer verification pipeline for our Ethereum-compatible contracts. This ensures our on-chain logic is universally transparent and instantly exposes our ABIs on Etherscan so the community can natively track and interact with the Ajo contracts through graphical explorer interfaces.

Key Changes
Automated Verification Script (

scripts/verify.ts
): Built a robust programmatic verification script bypassing manual ABI entry and constructor string encoding. The script automatically reads the deployment manifest (deployed-.json) to accurately extract deployed addresses and their exact, dynamically-injected constructor arguments in sync with the chain state.
Etherscan & Sourcify Configurations: Updated the root

hardhat.config.ts
and sub-project config to correctly map ETHERSCAN_API_KEY to multi-chain configurations natively supported by the @nomicfoundation/hardhat-verify plugin. Integrated a sourcify fallback for decentralized, IPFS-backed alternative verification.
Streamlined Workflow: Added foundational NPM scripts (verify:sepolia and a chained deploy:verify:sepolia) yielding a single-command loop for compiling, deploying, saving metadata, and publishing verification requests seamlessly.
Documentation Overhaul: Rewrote

CONTRACT_VERIFICATION.md
to offer crystal-clear, actionable steps detailing both Etherscan (EVM) and Stellar Expert (Soroban) workflows, with added troubleshooting guidance for developers.
Typescript Context Isolation: Configured a dedicated

tsconfig.scripts.json
to process utility scripts exactly right for the Hardhat runtime (CommonJS + Node types), sidestepping module-resolution conflicts with our Next.js frontend architecture.

closes #165

…swalla#165)

- Added robust scripts/verify.ts to programmatically verify AjoCircle and AjoFactory
- Extracted verified addresses and constructor arguments automatically from deploy manifest
- Updated hardhat config with multi-chain Etherscan & Sourcify support
- Added NPM scripts deploy:verify:sepolia to streamline full deployment loop
- Rewrote CONTRACT_VERIFICATION.md with clear community steps
@vercel
Copy link
Copy Markdown

vercel bot commented Mar 30, 2026

@Josetic224 is attempting to deploy a commit to the adeswalla's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave
Copy link
Copy Markdown

drips-wave bot commented Mar 30, 2026

@Josetic224 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Adeswalla Adeswalla merged commit 1cf9ee9 into Adeswalla:main Mar 30, 2026
1 check failed
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.

Verify Contracts on Etherscan

2 participants