【发布时间】:2019-11-03 19:16:29
【问题描述】:
我目前在基本的第一个网络上运行 hyperledger explorer 时遇到问题,在使用 ./createdb.sh 设置 postgresql 并运行 ./main.sh install 没有问题后,我碰巧卡在了 ./main.sh 测试命令显示错误:
PS : 我还编辑了 explorerconfig.json,如下所示,我还在 postgrespgtest.js 做了一些更改,如下所示。
explorerconfig.json
{
"persistence": "postgreSQL",
"platforms": ["fabric"],
"postgreSQL": {
"host": "127.0.0.1",
"port": "5432",
"database": "fabricexplorer",
"username": "postgres",
"passwd": "1234"
},
"sync": {
"type": "local",
"platform": "fabric",
"blocksSyncTime": "1"
},
"jwt": {
"secret": "a secret phrase!!",
"expiresIn": "2h"
}
}
与:
postgrespgtest.js
...
const options = {
testdb: 'pgtestdb',
messages: false,
connection: {
host: pgconfig.host,
port: pgconfig.port,
user: 'postgres',
password: '1234'
}
};
...
带有错误信息:
# Test Results
ok 1 DROP USER IF EXISTS testuser;
not ok 2 WITH PASSWORD 'password';
---
operator: fail
at: <anonymous> (/home/ec2-user/blockchain-explorer/app/test/postgrespgtest.js:2:5157)
stack: |-
Error: WITH PASSWORD '1234';
at Test.assert [as _assert] (/home/ec2-user/blockchain-explorer/app/test/node_modules/tape/lib/test.js:226:54)
at Test.bound [as _assert] (/home/ec2-user/blockchain-explorer/app/test/node_modules/tape/lib/test.js:77:32)
at Test.fail (/home/ec2-user/blockchain-explorer/app/test/node_modules/tape/lib/test.js:319:10)
at Test.bound [as fail] (/home/ec2-user/blockchain-explorer/app/test/node_modules/tape/lib/test.js:77:32)
at /home/ec2-user/blockchain-explorer/app/test/postgrespgtest.js:2:5157
at processTicksAndRejections (internal/process/task_queues.js:93:5)
...(many more errors)
有人知道是什么原因造成的吗? P.S : 如果资源不够,请发表评论,我会尽力给你的
【问题讨论】:
标签: hyperledger hyperledger-explorer