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

JsonError needs an easy way to convert the whole thing to a string #1059

Open
distinctdan opened this issue Mar 18, 2025 · 1 comment
Open

Comments

@distinctdan
Copy link

Feature description

I'm trying to log the error when my server returns a 400. This has turned out to be difficult because JsonError doesn't have a human readable toString() function. Instead, it just returns the message and ignores all the embedded errors, which is what I actually care about. I didn't even expect to have to deal with a response object here in RequestFilter, I expected to be able get the response body as a string. I'm not sure having a response object is bad, it just makes it hard to log the response. I could serialize it, but then I'm double serializing, which is inefficient.

@ojebari-ma
Copy link
Member

Could you please provide a reproducible example?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants