Skip to content

LoomProvider should use a dummy address when making static calls #291

@enlight

Description

@enlight

Currently the LoomProvider API requires a private key to be passed into the constructor

privateKey: Uint8Array,

Frequently users will be constructing a LoomProvider for use with eth-signing, in which case the private key isn't actually needed. The private key should be optional, if it's not provided a dummy address should be used.

A related problem is that if a dummy private key is specified when constructing LoomProvider and callerChainId is set (as is usually the case when doing eth-signing) then the address used for static calls has the callerChainId prefix - which is the wrong prefix since the private key is always expected to be a native ed25519 key, and therefore the chain ID should always match the client chain ID.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions