Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error getting code Getting chaincode took too long #7

Open
HugoPu opened this issue May 12, 2017 · 1 comment
Open

Error getting code Getting chaincode took too long #7

HugoPu opened this issue May 12, 2017 · 1 comment

Comments

@HugoPu
Copy link

HugoPu commented May 12, 2017

Hi,

I have trouble to run this app, could you please give some help? Thank you very much.
I built a Hyperledger Fabric 0.6 with the steps mentioned this link https://github.com/yeasy/docker-compose-files/tree/master/hyperledger/0.6, and used docker-compose -f 4-peers-with-membersrvc-explorer.yml up to run Fabric. Everything works well, I can use REST API to login, deploy, invoke and so on.

But when I try to run this app, I got the following error.

####################### Server Up - localhost:3000 #######################
loading hardcoded peers
loading hardcoded users
[ibc-js] Peer: vp0-vp0...:7050
[ibc-js] Registering vp0-vp0...:7050 w/enrollId - jim
[ibc-js] Registration success x1 : jim
[ibc-js] removing temp dir
[ibc-js] Downloading zip
redirect... https://codeload.github.com/ITPeople-Blockchain/auction/zip/master
[ibc-js] Downloading zip
[ibc-js] Unzipping zip
[ibc-js] Unzip done
[ibc-js] Scanning files [ 'art_app.go' ]
[ibc-js] Parsing file for shim version
[ibc-js] Found shim version: github.com/hyperledger/fabric/core/chaincode/shim
[ibc-js] Parsing file for invoke functions - art_app.go
[ibc-js] Parsing file for query functions - art_app.go
! [ibc-js] Warning - did not find any invoke functions in chaincode's "Invoke()", building a generic "invoke"
[ibc-js] Found cc invoke function: invoke
! [ibc-js] Warning - did not find any query functions in chaincode's "Query()", building a generic "query"
[ibc-js] Found cc query function: query
[ibc-js] load_chaincode() finished
############## DEPLOYING CHAINCODE ###########
[ibc-js] Deploy Chaincode - Starting
[ibc-js] function: init , arg: [ 'INITIALIZE' ]

     Waiting...


     deploy resp error - there is no chaincode hash name in response: { jsonrpc: '2.0',

error:
{ code: -32001,
message: 'Deployment failure',
data: 'Error when deploying chaincode: Error getting chaincode package bytes: Error getting code Getting chaincode took too long' },
id: 1494579923462 }
[]

then I checked the log in vp0:
09:05:53.474 [devops] getChaincodeBytes -> ERRO 04d Error getting chaincode package bytes: Error getting code Getting chaincode took too long 09:05:53.474 [devops] Deploy -> ERRO 04e Error deploying chaincode spec: type:GOLANG chaincodeID:<path:"https://github.com/ITPeople-Blockchain/auction/art/artchaincode" > ctorMsg:<args:"init" args:"INITIALIZE" > secureContext:"jim"
error: Error getting chaincode package bytes: Error getting code Getting chaincode took too long 09:05:53.474 [rest] processChaincodeDeploy -> ERRO 04f Error when deploying chaincode: Error getting chaincode package bytes: Error getting code Getting chaincode took too long 09:05:53.474 [rest] ProcessChaincode -> INFO 050 REST successfully deploy chaincode: {"jsonrpc":"2.0","error":{"code":-32001,"message":"Deployment failure","data":"Error when deploying chaincode: Error getting chaincode package bytes: Error getting code Getting chaincode took too long"},"id":1494579923462}

I modified localcreds.json as follow:
{
"credentials": {
"peers": [
{
"discovery_host": "127.0.0.1",
"discovery_port": 7050,
"api_host": "127.0.0.1",
"api_port_tls": 7050,
"api_port": 7050,
"type": "peer",
"container_id": "0f6ec070c8da",
"network_id": "598e8aeb090ce584182e67e33fe092400e704bd187a6d9ed48cba2854146ef7f",
"id": "vp0",
"api_url": "http://127.0.0.1:7050"
}
],
"ca": {
"membersrvc0": {
"url": "127.0.0.1:7054",
"discovery_host": "127.0.0.1",
"discovery_port": 7054,
"api_host": "127.0.0.1",
"api_port_tls": 7054,
"api_port": 7054,
"network_id": "598e8aeb090ce584182e67e33fe092400e704bd187a6d9ed48cba2854146ef7f",
"type": "ca",
"id": "membersrvc0",
"container_id": "5d8c5bb8d0b0"
}
},
"users": [
{
"username": "jim",
"secret": "6avZQLwcUe9b",
"enrollId": "jim",
"enrollSecret": "6avZQLwcUe9b"
}
]
}
}

@UbuntuEvangelist
Copy link

same here

screenshot from 2018-06-28 23 26 09

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants