cloudframeworks-blockchain / user-guide-fabric-smart-contract

[云框架]基于区块链的智能合约 / Blockchain, Fabric Hyperledger, Smart Contract / 区块链, Fabric Hyperledger, 智能合约
Other
275 stars 95 forks source link

调用失败,麻烦您指导一下 #2

Open jetzhow opened 6 years ago

jetzhow commented 6 years ago

1、按照流程安装和准备完毕,执行以下命令: peer chaincode invoke -n charity -c '{"Args":["donation", "mike", "2000"]}' -C myc 报错: Error: Error endorsing invoke: rpc error: code = Unknown desc = could not find chaincode with name 'charity' - make sure the chaincode charity has been successfully instantiated and try again - 2、以为是初始化的问题,接着我先去尝试install: peer chaincode install -p chaincodedev/chaincode/charity -n charity -v 0 报错: Error: Error endorsing chaincode: rpc error: code = Unknown desc = chaincode error (status: 500, message: Error installing chaincode code charity:0(chaincode /var/hyperledger/production/chaincodes/charity.0 exists)) 3、已存在,然后去init: peer chaincode instantiate -n charity -v 0 -c '{"Args":[]}' -C myc 报错: Error: Error endorsing chaincode: rpc error: code = Unknown desc = Failed to init chaincode(handler not found for chaincode charity:0)

请指教!

cmuCoppelia commented 5 years ago

我遇到了同样的问题,请问您解决了吗?