我在ubuntu 16.04 VM上设置了一个光纤网络(v1.1.0)。我想将该网络连接到超级分类帐浏览器,以查看不同对等方的块和分类帐副本,我正在使用此https://github.com/hyperledger/blockchain-explorer个回购。
我尝试构建资源管理器时的编译警告
nik@nik-VirtualBox:~/fabric-samples/blockchain-explorer/client$ npm run build
hyperledger-explorer-client@0.3.0 build /home/nik/fabric-samples/blockchain-explorer/client
react-scripts build
Creating an optimized production build...
Compiled with warnings.
./src/components/View/LandingPage.js
Line 18: 'getChannelListCreator' is defined but never used no-unused-vars
Line 19: 'getChannelCreator' is defined but never used no-unused-vars
./src/components/Panels/Notifications.js
Line 19: Useless constructor no-useless-constructor
./src/components/Lists/Chaincodes.js
Line 7: 'Pagination' is defined but never used no-unused-vars
./src/components/Forms/Channel.js
Line 8: 'Input' is defined but never used no-unused-vars
Line 8: 'InputLabel' is defined but never used no-unused-vars
Line 9: 'FormGroup' is defined but never used no-unused-vars
Line 9: 'FormControl' is defined but never used no-unused-vars
Line 9: 'FormHelperText' is defined but never used no-unused-vars
Line 29: Useless constructor no-useless-constructor
./src/components/Lists/Blocks.js
Line 95: Links must not point to "#". Use a more descriptive href or use a button instead jsx-a11y/href-no-hash
Search for the keywords to learn more about each warning.
To ignore, add // eslint-disable-next-line to the line before.
File sizes after gzip:
332.32 KB build/static/js/main.e33e1c6b.js
22.58 KB build/static/css/main.1f5927af.css
The project was built assuming it is hosted at the server root.
You can control this with the homepage field in your package.json.
For example, add this to build it for GitHub Pages:
"homepage" : "http://myname.github.io/myapp",
The build folder is ready to be deployed.
You may serve it with a static server:
npm install -g serve
serve -s build
我尝试运行资源管理器,我可以看到日志但是当我启动http://localhost:8080时显示错误
日志:
nik@nik-VirtualBox:~/fabric-samples/blockchain-explorer$ ./start.sh
nik@nik-VirtualBox:~/fabric-samples/blockchain-explorer$ tail -f log.log
at Object.fs.openSync (fs.js:646:18)
at Object.fs.readFileSync (fs.js:551:33)
at setupPeers (/home/nik/fabric-samples/blockchain-explorer/app/helper.js:60:19)
at Object.createDefault (/home/nik/fabric-samples/blockchain-explorer/app/helper.js:50:4)
at Object.start (/home/nik/fabric-samples/blockchain-explorer/app/timer/timer.js:38:12)
at Object.<anonymous> (/home/nik/fabric-samples/blockchain-explorer/main.js:25:7)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)