Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Network.ts - script hangs when reassigning w/ ContractFactory::deploy #113

Merged
merged 1 commit into from
Aug 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions packages/axelar-local-dev/src/Network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ export class Network {
const tokenHandler = await deployContract(wallet, TokenHandler, []);
const interchainTokenFactoryAddress = await this.create3Deployer.deployedAddress('0x', wallet.address, factorySalt);

let implementation = await deployContract(wallet, InterchainTokenServiceContract, [
const tokenServiceImplementation = await deployContract(wallet, InterchainTokenServiceContract, [
tokenManagerDeployer.address,
interchainTokenDeployer.address,
this.gateway.address,
Expand All @@ -250,16 +250,16 @@ export class Network {
]);
const factory = new ContractFactory(InterchainProxy.abi, InterchainProxy.bytecode);
let bytecode = factory.getDeployTransaction(
implementation.address,
tokenServiceImplementation.address,
wallet.address,
defaultAbiCoder.encode(['address', 'string', 'string[]', 'string[]'], [wallet.address, this.name, [], []])
).data;
await this.create3Deployer.connect(wallet).deploy(bytecode, deploymentSalt);
this.interchainTokenService = InterchainTokenServiceFactory.connect(interchainTokenServiceAddress, wallet);

implementation = await deployContract(wallet, InterchainTokenFactoryContract, [interchainTokenServiceAddress]);
const tokenFactoryImplementation = await deployContract(wallet, InterchainTokenFactoryContract, [interchainTokenServiceAddress]);

bytecode = factory.getDeployTransaction(implementation.address, wallet.address, '0x').data;
bytecode = factory.getDeployTransaction(tokenFactoryImplementation.address, wallet.address, '0x').data;

await this.create3Deployer.connect(wallet).deploy(bytecode, factorySalt);
this.interchainTokenFactory = InterchainTokenFactoryFactory.connect(interchainTokenFactoryAddress, wallet);
Expand Down
Loading