sxguan / fabric-go-sdk

89 stars 28 forks source link

提交链码时报错 #3

Open zhangbiao651 opened 1 year ago

zhangbiao651 commented 1 year ago

开始创建通道......

使用每个org的管理员身份更新锚节点配置... 使用每个org的管理员身份更新锚节点配置完成 创建通道成功 加入通道...... 加入通道成功 开始打包链码...... 打包链码成功 开始安装链码...... 安装链码成功 组织认可智能合约定义...... chaincode approved by Org1 peers: peer0.org1.example.com:7051 peer1.org1.example.com:9051 [fabsdk/util] 2022/11/22 23:39:27 UTC - lazyref.(Reference).refreshValue -> WARN Error - initializer returned error: load MSPs from config failed: configure MSP failed: sanitizeCert failed the supplied identity is not valid: x509: certificate signed by unknown authority. Will retry again later [fabsdk/util] 2022/11/22 23:40:27 UTC - lazyref.(Reference).refreshValue -> WARN Error - initializer returned error: load MSPs from config failed: configure MSP failed: sanitizeCert failed the supplied identity is not valid: x509: certificate signed by unknown authority. Will retry again later create chaincode lifecycle error: queryApprovedCC error: Org Org1 Peer peer0.org1.example.com:7051 NewInvoker error: Test status Code: (12) UNKNOWN. Description: LifecycleQueryApprovedCC returned error: querying for installed chaincode failed: Transaction processing for endorser [peer0.org1.example.com:7051]: Chaincode status Code: (500) UNKNOWN. Description: failed to invoke backing implementation of 'QueryApprovedChaincodeDefinition': could not fetch approved chaincode definition (name: 'simplecc', sequence: '1') on channel 'mychannel'exit status 255

这个问题大家有遇到过么 求指教

JovanniChen commented 1 year ago

应该是证书有错误,重新生成下再试试。

zhangbiao651 commented 1 year ago

非常感谢大佬的回复,问题解决了,具体原因是我使用了go1.19这个版本,通过gvm将版本降低到go1.17这个问题就解决了

cantincy commented 1 year ago

原来是Go版本的问题,终于解决了!太感谢了!

非常感谢大佬的回复,问题解决了,具体原因是我使用了go1.19这个版本,通过gvm将版本降低到go1.17这个问题就解决了

mamei1 commented 1 year ago

非常感谢大佬的回复,问题解决了,具体原因是我用了go1.19这个版本,通过gvm将版降到go1.17这个问题就解决了定了

我用的go1.18,报了你下面的那个错误就是创建链码周期错误,你go1.17没有这个错误了吗?

zihoolin commented 7 months ago

一定要用go1.17吗