feat(session): add client channel store#571
Conversation
commit: |
3eda1ae to
96aeaae
Compare
| export function canSignDescriptor( | ||
| account: ViemAccount, | ||
| descriptor: Channel.ChannelDescriptor, | ||
| authorizedSigner?: Address | undefined, |
There was a problem hiding this comment.
not directly related but noticed this felt dense and I think authorizedSigner is the smell here and as part of the session
mppx is built on passing in an account that is then used, so passing in an address override that can't even sign but we have to check against everywhere seems pointless
think it could likely be dropped and would simplify things a bit. if we really wanted to override the voucher signer it'd make more sense for something like voucherSigner: Account but probably fine to assume account == voucher signer for now
There was a problem hiding this comment.
talked with brendan in office and we agreed to just remove the authorizedSigner optionality on the client side for now... if this becomes a feature in the future, agree that voucherAccount is the better abstraction... updating
deodad
left a comment
There was a problem hiding this comment.
lgtm though think authorizedSigner could probably go might be worth seeing if brendan has an opinion
Summary
channelStorefor reusable TIP-1034 session channels.authorizedSigneroverride; voucher authority now comes from the selected account.Validation
VITE_TEMPO_NETWORK=none pnpm exec vp test --run src/tempo/session/client/CredentialState.test.ts src/tempo/session/client/Session.test.ts src/tempo/session/client/ChannelOps.test.ts src/tempo/session/client/SessionManager.test.tspnpm check:typespnpm check