-
Notifications
You must be signed in to change notification settings - Fork 2
fix(hermes): Eliminate almost all Debug print statements. #481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ut-hk/hermes into fix/reduce-use-of-Debug-print
… yet complete or production ready.
rafal-ch
reviewed
Aug 12, 2025
cong-or
previously approved these changes
Aug 12, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good, I would agree with the comments from Rafal if you get a chance.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
fyi: hermetics
For information - Hermes Backend, System Development & Integration Team
p: normal
The issue or pull request is of normal priority and can be addressed in due course
refactor
Code refactoring task
review me
PR is ready for review
rr: hermetics
Required review by hermes team
rust
Pull requests that update Rust code
squad: hermetics
Hermes Backend, System Development & Integration Team
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
In line with the move to try and remove Debug prints from anywhere but Unit Tests, and Debug builds, this PR removes
all but the Debug print lints from the wasm bindings.
There is currently an issue in clippy which prevents the clippy lint for these issues being silenced in a macro like
bindgen!
whichis why they have not silenced. There are also no
bindgen!
options to not emitDebug
implementations of automatically created types.During this process there were a couple of minor changes which helped the process.
anyhow!
this reduces the maintenance burden created by Typed errors, where no logic ever turns on the Error type itself.assert_*
macros have been derived, and only in debug builds.error!
logs using ToString which is equivalent to Display and just extracts the string in the anyhow! error, which is controlled and can not leak unexpected data. (Another reason to use Anyhow).todo!
because this is not production code. But this will need to be reverted before we are production ready.Related Issue(s)
No Specific Issue Yet
Breaking Changes
None, everything that was changed should be transparent.
Related Pull Requests
This was tested and built against this PR: input-output-hk/catalyst-ci#423
But that version is not used in this PR, because it is not yet ready to be merged, pending further testing.
Once merged, all these changes will eliminate a huge source of errors it will cause otherwise.
Please confirm the following checks