You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using httplog in combination with chi compress middleware logs compressed response body. Has anyone encountered similar issues before? I wrote a custom implementation of httplog where I manually decompress response, but I'm wondering if there is a cleaner solution?
To reproduce, add compress middleware to example and set Content-Type header to text/plain:
Example of console output when calling /warn endpoint with JSON: false and Concise: false:
where you can see response body logged as "\u001f�\u0008\u0000\u0000\u0000\u0000\u0000\u0000�*O,�S�H-J\u0005\u0004\u0000\u0000��?�\u001dv\t\u0000\u0000\u0000"
The text was updated successfully, but these errors were encountered:
Using
httplog
in combination with chi compress middleware logs compressed response body. Has anyone encountered similar issues before? I wrote a custom implementation ofhttplog
where I manually decompress response, but I'm wondering if there is a cleaner solution?To reproduce, add compress middleware to example and set
Content-Type
header totext/plain
:Example of console output when calling
/warn
endpoint withJSON: false
andConcise: false
:where you can see response body logged as
"\u001f�\u0008\u0000\u0000\u0000\u0000\u0000\u0000�*O,�S�H-J\u0005\u0004\u0000\u0000��?�\u001dv\t\u0000\u0000\u0000"
The text was updated successfully, but these errors were encountered: