axelarnetwork / axelar-local-dev Goto Github PK
View Code? Open in Web Editor NEWA local developer environment for building your cross-chain dapps.
A local developer environment for building your cross-chain dapps.
axelar-local-dev/src/networkUtils.ts
Lines 77 to 91 in 14368ee
seems replace ganache provider with a json-rpc provider should be fine,right? is it possible that we can do some refactor and reuse most of this repo to provisioning a live chain and deploy contracts required here https://github1s.com/axelarnetwork/axelar-local-dev/blob/HEAD/src/contracts/Gateway.sol
PS:
I'm developer from Parallel team and working on cross-chain integration with axelar bridge, now just copy and paste contracts and scripts for integration in this repo and hope to find a way not doing that.
This issue is not fixed:
Link to original closed issue: #2
Try running from a new hardhat project and installing axelar-local-dev according to the readme.
Then attempt to npx hardhat test
, it will give the same error:
Error: Cannot find module '../artifacts/@axelar-network/axelar-cgp-solidity/contracts/TokenDeployer.sol/TokenDeployer.json'
It doesn't have the TokenDeployer.json artifacts because it didn't compile the contracts in the node_modules @axelar-network directory.
Trying to add that directory to the hardhat.confg.js doesn't help.
Not sure how to get this running. Importing the entire test project seems to work fine, but I don't need all that.
Can we rename one or only have one so that folks understand how to use axelar-local-dev better?
axelar-local-dev/packages/axelar-local-dev/src/networkUtils.ts
Lines 28 to 31 in b32f4b5
I have tried blockscout, the axelar server crashes with:
TypeError: Cannot set properties of undefined (setting '0')
at /home/user/axelar-local-gmp-examples/node_modules/ganache/dist/node/1.js:2:127997
at Array.forEach ()
at /home/user/axelar-local-gmp-examples/node_modules/ganache/dist/node/1.js:2:127899
Can you suggest which blockexplorer to use?
axelar-local-gmp-examples
still depends on these deprecated versions
issues link here:
axelarnetwork/axelar-examples#40
When installing the package from npm and running it locally an error is thrown because lodash is used in utils.js but is not in package.json
Test example simple/sendToken.js
:
node node_modules/@axelar-network/axelar-local-dev/examples/simple/sendToken.js
node:internal/modules/cjs/loader:936
throw err;
^
Error: Cannot find module '../build/TokenDeployer.json'
Require stack:
- /Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/dist/Network.js
- /Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/dist/networkUtils.js
- /Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/examples/simple/sendToken.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:999:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/dist/Network.js:62:21)
at Module._compile (node:internal/modules/cjs/loader:1099:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:975:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:999:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'/Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/dist/Network.js',
'/Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/dist/networkUtils.js',
'/Users/gus/Documents/axelar/git-repos/axelar-local-dev/node_modules/@axelar-network/axelar-local-dev/examples/simple/sendToken.js'
]
}
Node.js v17.8.0
When calling relay
to trigger GMP executions the underlying EVMRelayer class deletes the gas event used to pay for the call.
(Relevant piece of code https://github.com/axelarnetwork/axelar-local-dev/blob/main/src/relay/EvmRelayer.ts#L125)
This breaks the expected behavior of gas being passed along for two-way-calls.
An easy workaround could be to have an optional parameter in relay
that disables the gas payment check completely
The script in README produces the following console output:
user1 has 1000 aUSDC.
user2 has 0 aUSDC.
user1 has 900 aUSDC.
user2 has 0 aUSDC.
I expect user2
to have 100 aUSDC at the end, not zero.
Now that we have comprehensive examples in https://github.com/axelarnetwork/axelar-local-gmp-examples we may wish to simply refer people there instead?
Hello, just to mention that the type Network is not exported as mentioned in the doc. Would be nice to have it available :)
It is not best practice to magically delete files from user's fs.
It can also cause issues with github where a user can inadvertently commit the local.json file
We are referencing branch feat/forecaller-service
of repository axelar-cgp-solidity
but as you can see here:
axelarnetwork/axelar-cgp-solidity#160 the branch has been closed and deleted now and this is causing npm install to fail with
`
npm ERR! code 1
npm ERR! The git reference could not be found
npm ERR! command git --no-replace-objects checkout feat/forecaller-service
npm ERR! error: pathspec 'feat/forecaller-service' did not match any file(s) known to git
npm ERR! A complete log of this run can be found in: /root/.npm/_logs/2023-06-20T19_26_29_124Z-debug-0.log
`
When using the afterRelay callback the object is not properly reset.
Which makes event logging hard since there is no way of knowing if those events
have been logged before.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.