...by Daniel Szego
quote
"Simplicity is the ultimate sophistication."
Leonardo da Vinci

Saturday, July 7, 2018

Fabric composer tips and tricks - logging in a transaction


Error handling in Hyperledger Fabric composer it a little bit tricky, especially if it is on runtime errors and you want to create complex business logic with complex transactions. What you can do however is to simply use the standard javascript console for logging events and errors:

  console.log('My event');  
  console.log('My error');  

At executing the transaction like in the Fabric composer playground, the error message will be logged in the console of your browser.