Skip to content

Commit

Permalink
wallet: skale: deploy gas limit = 10m
Browse files Browse the repository at this point in the history
  • Loading branch information
attente committed Nov 7, 2024
1 parent df6d53a commit 69108ca
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions packages/wallet/src/wallet.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { ethers } from 'ethers'
import { commons, v1, v2 } from '@0xsequence/core'
import { ChainId } from '@0xsequence/network'
import { SignatureOrchestrator, SignerState, Status } from '@0xsequence/signhub'
import { encodeTypedDataDigest, subDigestOf } from '@0xsequence/utils'
import { FeeQuote, Relayer } from '@0xsequence/relayer'
Expand Down Expand Up @@ -65,7 +66,7 @@ export class Wallet<
public context: commons.context.WalletContext
public config: Y
public address: string
public chainId: ethers.BigNumberish
public chainId: bigint

public relayer?: Relayer

Expand All @@ -78,7 +79,9 @@ export class Wallet<
private _reader?: commons.reader.Reader

constructor(options: WalletOptions<T, Y, Z>) {
if (BigInt(options.chainId) === 0n && !options.coders.signature.supportsNoChainId) {
const chainId = BigInt(options.chainId)

if (chainId === 0n && !options.coders.signature.supportsNoChainId) {
throw new Error(`Sequence version ${options.config.version} doesn't support chainId 0`)
}

Expand All @@ -89,7 +92,7 @@ export class Wallet<
this.orchestrator = options.orchestrator
this.coders = options.coders
this.address = options.address
this.chainId = options.chainId
this.chainId = chainId
this.relayer = options.relayer

this._reader = options.reader
Expand Down Expand Up @@ -219,7 +222,7 @@ export class Wallet<
{
to: context.factory,
data: factoryInterface.encodeFunctionData(factoryInterface.getFunction('deploy')!, [context.mainModule, imageHash]),
gasLimit: 100000,
gasLimit: this.chainId === ChainId.SKALE_NEBULA ? 10000000 : 100000,

Check failure on line 225 in packages/wallet/src/wallet.ts

View workflow job for this annotation

GitHub Actions / Run build

Property 'chainId' does not exist on type 'typeof Wallet'.
delegateCall: false,
revertOnError: true,
value: 0
Expand Down

0 comments on commit 69108ca

Please sign in to comment.