coinbase / smart-wallet

MIT License
304 stars 57 forks source link

Feature request: force deploy of newly minted smart wallet code to blockchain #85

Open Ncastro878 opened 3 weeks ago

Ncastro878 commented 3 weeks ago

I am looking to integrate the soinbase smart wallet into my app. We primarily use the USDC token and one feature used is the permit() function with an offchain gassless signature that authorizes an allowance of usdc for another address; the smart wallet owner van sign the permit message and authorize another address to spend their usdc.

However, it seems the USDC code only accepts the signature from smart wallets that have deployed their code to the blockchain, not newly minted predeployed wallets. I have raised the issue here: https://github.com/circlefin/stablecoin-evm/issues/470

So in order for a smart wallet to sign a permit signature for usdc they must initiate a transaction that will trigger the deployment of the wallet code to the blockchain.

Perhaps there already exists a way to force a smart wallet to deploy to its code, but if not I think this would be a helpful feature for edge cases like this one.

I can elaborate further if needed.

wilsoncusack commented 3 days ago

Hey @Ncastro878, this makes sense. Are you using the Coinbase Wallet SDK?

Ncastro878 commented 3 days ago

@wilsoncusack I am not. I am using web3modal to sign users in, and that allows users to pick between coinbase mobile app or coinbase smart wallet for connecting.