zalando-incubator/clin

Dumping contains terminal colour codes

Closed this issue · 1 comments

Expected Behavior

When dumping a schema to a file, I expect valid json or yaml output

e.g.

{
  "name": "my-event-type",
  "category": "data",
...

Actual Behavior

The output contains terminal colour codes, and out.json contains:

{
  �[38;2;0;128;0;01m"name"�[39;00m: �[38;2;186;33;33m"my-event-type"�[39m,
  �[38;2;0;128;0;01m"category"�[39;00m: �[38;2;186;33;33m"data"�[39m,

Steps to Reproduce the Problem

  1. clin dump -t "$token" -o json -e 'production' 'my-event-type' > out.json
  2. cat out.json

Specifications

  • Version: clin-1.0.1, Python 3.8.2
  • Platform: macOS Big Sur

Thanks for the fix @herojan !