мы пытаемся вызвать цепной код с помощью следующей команды:
FABRIC_CFG_PATH=${PWD} CORE_PEER_LOCALMSPID=org1MSP CORE_LOGGING_LEVEL=debug CORE_PEER_TLS_ENABLED=true CORE_PEER_TLS_CLIENTAUTHREQUIRED=true CORE_PEER_MSPCONFIGPATH=msp CORE_PEER_TLS_CLIENTCERT_FILE=user-org1-tls.pem CORE_PEER_TLS_CLIENTKEY_FILE=user-org1-tls.key peer chaincode invoke -C dscsa -n mycc -c '{"Args":["create","00000"]}' -o orderer1-ord:7050 --tls --cafile ord-ca-chain.pem --peerAddresses peer3-org1:7051 --tlsRootCertFiles org1-ca-chain.pem --peerAddresses peer3-org2:7051 --tlsRootCertFiles org2-ca-chain.pem --peerAddresses peer3-org3:7051 --tlsRootCertFiles org3-ca-chain.pem
но получите эту ошибку:
2019-03-21 19:04:37.459 UTC [msp] Validate -> DEBU 036 MSP org1MSP validating identity
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x60 pc=0x110fddc]
goroutine 1 [running]:
github.com/hyperledger/fabric/peer/common.NewPeerClientForAddress(0x7ffd955fe783, 0x9, 0x7ffd955fe7a0, 0x10, 0x8fb52c, 0x9e8745, 0x14848a7)
/opt/gopath/src/github.com/hyperledger/fabric/peer/common/peerclient.go:44 +0x8c
github.com/hyperledger/fabric/peer/common.GetEndorserClient(0x7ffd955fe783, 0x9, 0x7ffd955fe7a0, 0x10, 0x4, 0x1, 0xc4205d1988, 0x9e5bec)
/opt/gopath/src/github.com/hyperledger/fabric/peer/common/peerclient.go:122 +0x56
github.com/hyperledger/fabric/peer/chaincode.InitCmdFactory(0x1482fcf, 0x6, 0x101, 0x1a, 0x13b1dc0, 0xc420181f90)
/opt/gopath/src/github.com/hyperledger/fabric/peer/chaincode/common.go:369 +0xb19
github.com/hyperledger/fabric/peer/chaincode.chaincodeInvoke(0xc4200d9680, 0x0, 0x0, 0x0)
/opt/gopath/src/github.com/hyperledger/fabric/peer/chaincode/invoke.go:53 +0xff
github.com/hyperledger/fabric/peer/chaincode.invokeCmd.func1(0xc4200d9680, 0xc4202be600, 0x0, 0x17, 0x0, 0x0)
/opt/gopath/src/github.com/hyperledger/fabric/peer/chaincode/invoke.go:26 +0x34
github.com/hyperledger/fabric/vendor/github.com/spf13/cobra.(*Command).execute(0xc4200d9680, 0xc4202be480, 0x17, 0x18, 0xc4200d9680, 0xc4202be480)
/opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/spf13/cobra/command.go:698 +0x46d
github.com/hyperledger/fabric/vendor/github.com/spf13/cobra.(*Command).ExecuteC(0x1c90320, 0x1d78c30, 0xf, 0x1)
/opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/spf13/cobra/command.go:783 +0x2e4
github.com/hyperledger/fabric/vendor/github.com/spf13/cobra.(*Command).Execute(0x1c90320, 0x1, 0xffffffffffffffff)
/opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/spf13/cobra/command.go:736 +0x2b
main.main()
/opt/gopath/src/github.com/hyperledger/fabric/peer/main.go:97 +0x5bf
мы используем v1.3 ткани. как мы можем это исправить?