Does launchTestNode automatically apply a salt to contracts?

I’m running my test node as follows:

const launched = await launchTestNode({
      walletsConfig: {
        count: 4, // Number of wallets to create
        assets, // Assets to use
        coinsPerAsset: 2, // Number of coins per asset
        amountPerCoin: 1_000_000, // Amount per coin
        messages: [message], // Initial messages
      },
      nodeOptions: {
        port: "4000",
      },
      contractsConfigs: [
        {
          deployer: OctaneFeeSplitterContractAbi__factory, // Contract deployer factory
          bytecode: octaneFeeSplitterBytecode, // Contract bytecode,
          walletIndex: 0, // Index of the wallet to deploy the contract
        },
      ],
    });

const {
      contracts: [
        feeSplitterContract,
      ],
      wallets: [wallet1, wallet2, wallet3, wallet4],
      provider
    } = launched;

I would expect the feeSplitterContract to have the same id each time. Does launchTestNode automatically apply salt?

1 Like

Found the solution: The deployContract has options which allow you to set the salt to a fixed value.

I am glad it worked for you. Lmk if you need any other help

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.