More options for --keep-traces
#730
Replies: 5 comments 6 replies
-
There's actually no difference between user-defined traces and traces coming from the stdlib. The stdlib is user-defined! There are some traces defined directly by the compiler though but I wonder what the use case is here? It sounds like something that could be potentially quite confusing. |
Beta Was this translation helpful? Give feedback.
-
Yeah I'm aware of this.
We prefer to leave traces on for our on-chain code for debugging purposes. It's easier to troubleshoot and quickly respond to errors even on mainnet. Based on our experience, it's a good decision to use validators with traces on. But the traces in Aiken are bloated - since they're meant just for developer experience purposes so it's understandable that they're verbose. This makes our validators compiled with For the purposes mentioned above it would make most sense to us to leave just the user defined traces on and turn off the Aiken traces. And even maybe make this behaviour configurable per library. |
Beta Was this translation helpful? Give feedback.
-
To revisit this. How about Aiken has short url links for the traces instead of wordy long sentence traces. Then people could follow the url to get a good user experience on how to solve their trace. @rvcas |
Beta Was this translation helpful? Give feedback.
-
I am using traces instead of code comments relying on the fact that aiken makes it trivial to build without. Any thoughts on having something akin to logging levels on traces? I cant think of a way of doing this that is worth the added complexity but it would be alt way to accommodate this. Something like: providing error codes and being able to filter on them. Simply commenting and uncommenting is not so seemless. The formatter eagerly strips braces where the trace has only one sibling and uncommenting is then invalid syntax. |
Beta Was this translation helpful? Give feedback.
-
Now we will have more options soon #800 |
Beta Was this translation helpful? Give feedback.
-
I'd like to be able to disable all Aiken trace messages but keep just the user defined.
The tracing is done via the
builtin.debug
or the builtinfail
where the tracing effect of these functions is enabled when the--keep-traces
is passed to the compilation command, but it includes all the traces from the language and libs (stdlib, etc.), too.Beta Was this translation helpful? Give feedback.
All reactions