Skip to content
This repository has been archived by the owner on May 2, 2022. It is now read-only.

Add console for debug output of smart contract executions #107

Open
Robbepop opened this issue Jun 7, 2021 · 1 comment
Open

Add console for debug output of smart contract executions #107

Robbepop opened this issue Jun 7, 2021 · 1 comment

Comments

@Robbepop
Copy link

Robbepop commented Jun 7, 2021

The new and upcoming seal_debug_print call no longer directly prints the debug output to the Substrate console.
Instead it is stored into a buffer which can be retrieved by a dedicated RPC call.
Therefore it will become important for UI tools such as Canvas UI to properly show the debug output after each smart contract execution or chain of smart contract execution in some "console" style output for inspection.

I think for an MVP it is totally fine to style this in the way a console would look to most developers since that is what they probably expect from this output. It may not yet be possible but a future upgrade and extension to this console output is to also include the addresses of the contracts and the call chains i.e. backtrace of all the calls starting from a smart contract invocation from the user.

cc @cmichi , @athei

@athei
Copy link
Member

athei commented Jun 7, 2021

Please note that this buffer can still be printed to the console:
https://github.com/paritytech/substrate/tree/master/frame/contracts#debugging

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

No branches or pull requests

2 participants