Skip to content

Body encoding detection #567

@vbuberen

Description

@vbuberen

✍️ Describe the bug

Opening this issue to not lose it.

After recent additions of custom encoders in #555 a new bug appeared with body content detection. Namely, empty bodies began to appear in Chucker UI as encoded or binary. In attempt to fix this issue I created #562 , but as @MiSikora noted it doesn't fix the bug in general.
It seems that current logic with defining bodies as isPlainText won't work anymore and instead transaction object should use isEncoded property.
A little more context is available here

💣 Steps to reproduce

Open some encoded transaction, like some of Postman echo one with proto content in Chucker sample.

🔧 Expected behavior

Empty bodies are shown as body is empty
Encoded bodies are shown as encoded or binary body omitted
Decoded bodies are shown completely with no additional strings from Chucker side.

📷 Screenshots

The bug in request body with pokemon data.
Screenshot 2021-02-17 at 12 11 46

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions