Skip to content

fix: add Ethereum address checksum validation tool #953

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

crStiv
Copy link

@crStiv crStiv commented Mar 28, 2025

Implemented Features:

  • New Go tool in ops/cmd/check_addresses that finds and fixes incorrectly checksummed Ethereum addresses
  • Added CI check to prevent merging files with incorrect address formats
  • Tool can check specific files, all TOML files, or just the standard-versions-sepolia.toml
  • Fails with exit code 1 when bad addresses are found (for CI integration)

Background:

Issue #938 pointed out that non-checksummed addresses cause problems when importing into Solidity. So I guess my fix can help with solving the issue.

Testing Done:

I've tested this by manually invalidating addresses and confirming the tool catches and fixes them correctly. Added docs explaining usage and command flags.

Screenshots:

  1. Start of the process
    Screenshot 2025-03-28 135243
  2. The tool finding an incorrect address
    Screenshot 2025-03-28 135301
  3. Fixing it with the -fix flag
    Screenshot 2025-03-28 135411
  4. Verifying all addresses now pass validation
    Screenshot 2025-03-28 135533

@crStiv crStiv requested a review from a team as a code owner March 28, 2025 13:07
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