Skip to content
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

Fixed error message for too long hrp prefix #179

Merged
merged 3 commits into from Mar 5, 2024

Conversation

DariuszDepta
Copy link
Contributor

@DariuszDepta DariuszDepta commented Mar 4, 2024

closes #178

@apoelstra
Copy link
Member

Hi @DariuszDepta, thanks for the contribution! Can you run cargo fmt on this?

concept ACK this change.

I'm a little unsure if we want unit tests on the Display of our error types. In theory they are part of the public API and they shouldn't change, but on the other hand we may want the flexibility to change them anyway. And if people care about the exact output they should be able to destructure the errors and recreate their own messages.

@tcharding
Copy link
Member

I also would prefer to see the error variants tested against instead of the error strings, including the strings is a maintenance burden that adds little value IMO (taking into consideration the bit @apoelstra said about technically beig part of the API).

ACK the non-test bit though, thanks for fixing it!

@DariuszDepta
Copy link
Contributor Author

I guess it is ready to merge.

Copy link
Member

@apoelstra apoelstra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK c0220d8 though in future, please squash together commits which modify previous commits

@apoelstra apoelstra merged commit cd20221 into rust-bitcoin:master Mar 5, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Wrong error message
3 participants