OffchainLabs / demo-dapp-pet-shop

Pet shop dapp, for use as an Arbitrum demo
Apache License 2.0
20 stars 9 forks source link

meet errors while compile this project #30

Open catiga opened 2 years ago

catiga commented 2 years ago

use "truffle migrate --network arbitrum" to build project, got below errors, how to solve it?

Compiling your contracts...

/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/internal/eachOfLimit.js:61 callback(null); ^ Error: couldn't get chain id at /Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/arb-ethers-web3-bridge/index.js:37:14 at /Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/@trufflesuite/web3-provider-engine/index.js:238:9 at /Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/internal/once.js:12:16 at replenish (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/internal/eachOfLimit.js:61:25) at /Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/internal/eachOfLimit.js:71:9 at eachLimit (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/eachLimit.js:43:36) at /Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/async/internal/doLimit.js:9:16 at end (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/@trufflesuite/web3-provider-engine/index.js:217:5) at Request._callback (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/@trufflesuite/web3-provider-engine/subproviders/rpc.js:36:21) at self.callback (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/request/request.js:185:22) at Request.emit (events.js:400:28) at Request.onRequestError (/Users/jackielee/Documents/devworkspace/arbitrum/demo-dapp-pet-shop/node_modules/request/request.js:877:8) at ClientRequest.emit (events.js:412:35) at Socket.socketErrorListener (_http_client.js:475:9) at Socket.emit (events.js:400:28) at emitErrorNT (internal/streams/destroy.js:106:8)

catiga commented 2 years ago

@edfelten @hkalodner i wanna learn and test arbitrum, pls help to fix this, thanks

longmans commented 2 years ago

If you encounter the same problem, you can use this demo instead: https://github.com/OffchainLabs/arbitrum-tutorials/tree/master/packages/demo-dapp-pet-shop

kwnm commented 1 year ago

@catiga try this.

arbitrum: { provider: function () { return wrapProvider( new HDWalletProvider(mnemonic, 'https://rinkeby.arbitrum.io/rpc') ) }, network_id: 421611, gas: 287853530, },