Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Decoded panics (and maybe revert strings?) should have an appropriate field in interpretations #6020

Open
haltman-at opened this issue May 5, 2023 · 0 comments

Comments

@haltman-at
Copy link
Contributor

haltman-at commented May 5, 2023

Currently, when printing out the decoded result of a revert, panics often get special handling so we can print out a human-readable interpretation of what the panic means (using the panicString function from debug-utils). However, checking for this case is still a pain.

Instead, decoded panics should get an appropriate interpretation (in interpretations), and the ReturndataDecodingInspector should make use of this interpretation. The panicString function can be moved inside Codec, and called from ReturndataDecodingInspector. This would save some repeated annoying manual special cases.

Edit: Arguably, this should apply to ordinary revert strings as well! However it's more important for panics.

Environment

  • Truffle version (truffle version): 5.8.4
@haltman-at haltman-at changed the title Decoded panics should have an appropriate field in interpretations Decoded panics (and maybe revert strings?) should have an appropriate field in interpretations May 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants