feat: ERC-4337 smart account classification + admin wallet type override#164
Merged
Conversation
- address-classifier: detect ERC-4337 accounts via validateUserOp selector (0x3a871cdd) before falling back to smart_contract; new smart_account type - wallet-eligibility: add smart_account to BOOKS_ELIGIBLE_ADDRESS_TYPES so manifest-declared smart accounts produce attributed books - new PATCH /api/admin/registry/update-wallet-type endpoint to manually correct misclassified wallet address_type without raw SQL - luca-admin: Wallet Type Override card — input address + dropdown override type Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RjpGP3kYKnQuQAUoK6RZky
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
address-classifier.ts— addsvalidateUserOpselector check (0x3a871cdd) before thesmart_contractfallback. Smart accounts (Abstract, Coinbase, Biconomy, ZeroDev, etc.) now classify assmart_accountinstead ofsmart_contractwallet-eligibility.ts—smart_accountadded toBOOKS_ELIGIBLE_ADDRESS_TYPESso manifest-declared smart accounts produce attributed revenuePATCH /api/admin/registry/update-wallet-type— override a wallet'saddress_typewithout raw SQL/luca-admin— Wallet Type Override form: address input + type dropdown + submitWhy
Agents running on ERC-4337 smart accounts (increasingly common) submitted wallets via manifest but showed "not valid for books" because the classifier saw bytecode and fell through to
smart_contract. This fixes the classification permanently for future submissions and provides an admin override for existing affected wallets (e.g. Skopos).Manual step after merge
Use the new Wallet Type Override card in luca-admin to fix Skopos's existing wallet row — set
address_typetosmart_account. No SQL needed.Generated by Claude Code