Open marcomarasco opened 5 years ago
I tested this api to get the expected return value.
curl 'http://localhost:8545/' -H 'Content-Type: application/json' --data-binary '{"jsonrpc":"2.0","id":1,"method":"net_version","params":[]}'
{"jsonrpc": "2.0", "result": 5777, "id": 1}
Please check your execution environment.
I tested this api to get the expected return value.
curl 'http://localhost:8545/' -H 'Content-Type: application/json' --data-binary '{"jsonrpc":"2.0","id":1,"method":"net_version","params":[]}'
{"jsonrpc": "2.0", "result": 5777, "id": 1}
Using curl I also get the correct response.
Please check your execution environment.
@uldaman my execution environment uses react + thorify + web3 v.1.0.0-beta.37
+ truffle (truffle-contract
).
In your opinion what can cause this behavior?
Hi @marcomarasco thorify and web3-gear can not work together, this link will help you understand the difference
@libotony my apologyze, i didn't explain myself very well. Looking at your link the solution I adopted is the one at point 2
- An alternative for web application:
Thorify + Web3 + Comet
So the environment is.
Local SOLO Thor Node using Thor
+ Web3-Gear
proxy. This allows me to deploy contract on SOLO net using Truffle suite. And log the actions on local chain during development and tests.
dApp using React
+ Drizzle
+ Thorify
+ Web3
+ Comet
The error mentioned above in previous messages is retrieved using dApp and truffle-contract when i tried to init a new SC from ABI created during deploy with truffle compile
(and migrate
).
Have a look at contract
export method from truffle-contract for further informations.
Please show more error information when web3-gear goes wrong.
As you can see here the first one is the error generated via dApp.
The second one is from Google Chrome console when i'm trying to invoke window.web3.eth.net.getNetworkType()
method.
@uldaman and @libotony this can be a behavior related to web3? Or "thorified" web3 instance instead?
You are using Comet
then the provider is from Comet
and I am not sure if this provider is compatible with truffle-contract. What I am sure of is the provider from thorify is not compatible with package truffle-contract, if you are trying to deploy the contract to testnet or mainnet, I would suggest you use https://inspector.vecha.in
@libotony how can i use Truffle to deploy contracts on Testnet?
$ web3-gear --log 1 --debug 1 --host https://sync-testnet.vechain.org --port 8669
This command will fail after few seconds, maybe due timeout.
It is recommended to connect to the local node
I also met this problem when using web3-gear + @openzeppelin/truffle-upgrades to deploy smart contract.
having similar issues with testnet and local node. getting a 500 internal server error. is this project still active?
Got the following error during transactions.
Error: Wrong response id "3477728465" (expected: "1") in {"jsonrpc":"2.0","id":1,"method":"net_version","params":[]}
Wonder if there is a particular network id mapping to avoid this.