Commit 348c677c authored by David Enyeart's avatar David Enyeart
Browse files

[FAB-14459] Improve error for key level endorsement



Add a hint about root cause - application capability V1_3 required.

Change-Id: I4c72c4972f31732dff2e6aadd303853d5a1c79e7
Signed-off-by: default avatarDavid Enyeart <enyeart@us.ibm.com>
parent 5be77553
......@@ -572,7 +572,7 @@ func (h *Handler) checkMetadataCap(msg *pb.ChaincodeMessage) error {
}
if !ac.Capabilities().KeyLevelEndorsement() {
return errors.New("key level endorsement is not enabled")
return errors.New("key level endorsement is not enabled, channel application capability of V1_3 or later is required")
}
return nil
}
......
......@@ -682,7 +682,7 @@ var _ = Describe("Handler", func() {
It("returns an error", func() {
_, err := handler.HandlePutStateMetadata(incomingMessage, txContext)
Expect(err).To(MatchError("key level endorsement is not enabled"))
Expect(err).To(MatchError("key level endorsement is not enabled, channel application capability of V1_3 or later is required"))
})
})
......@@ -1101,7 +1101,7 @@ var _ = Describe("Handler", func() {
It("returns an error", func() {
_, err := handler.HandleGetStateMetadata(incomingMessage, txContext)
Expect(err).To(MatchError("key level endorsement is not enabled"))
Expect(err).To(MatchError("key level endorsement is not enabled, channel application capability of V1_3 or later is required"))
})
})
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment