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

fix: map deserde error to ErrorResp if it is an error payload #236

Merged
merged 2 commits into from
Feb 28, 2024

Conversation

mattsse
Copy link
Member

@mattsse mattsse commented Feb 28, 2024

currently all deserde failures are returned as deser_error

this adds a check for error payload if deserialization failed

@mattsse mattsse force-pushed the matt/try-deserializing-error-payload branch from ca4889f to 00fa9e6 Compare February 28, 2024 15:56
@prestwich
Copy link
Member

check if this logic error is duplicated in the other transports? Maybe make a convenience function in the jsonrpc crate for doing this conversion?

@mattsse
Copy link
Member Author

mattsse commented Feb 28, 2024

we could add it to fn deser_err because this already gets the text?

@mattsse mattsse requested a review from DaniPopes February 28, 2024 16:09
@DaniPopes DaniPopes merged commit e7edba5 into main Feb 28, 2024
13 of 14 checks passed
@DaniPopes DaniPopes deleted the matt/try-deserializing-error-payload branch February 28, 2024 21:52
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.

3 participants