colortail
colortail copied to clipboard
behaviour with json unicode strings
Hello! i tried this util and it's great for coloring tail output, the exact one i was looking for!
The only issue i found is that it can't handle plain-text lines with unicode-marced substrings.
Like this one:
Updating cache with info: [VIF({'profile': None, 'ovs_interfaceid': None, 'network': Network({'bridge': u'xenbr1', 'subnets': [Subnet({'ips': [FixedIP({'meta': {}, 'version': 4, 'type': u'fixed', 'floating_ips': [], 'address': u'10.1.9.10'})], 'version': 4, 'meta': {u'dhcp_server': u'10.1.9.11'}, 'dns': [], 'routes': [], 'cidr': u'10.1.9.0/24', 'gateway': IP({'meta': {}, 'version': 4, 'type': u'gateway', 'address': u'10.1.9.1'})})
colortail thinks that strings like u'blabla'
are unicode-encoded and tries to show unicode characters instead of plain text.
so i'm getting smth like this(sorry, i can't even paste it here properly):
u'0d260▒`28X▒f-X▒6c76-499182```
instead of this:
u'971c4e48-1596-4b61-bfb3-d38ed1cec9fb'
is there a way to disable this behavior?
Um. Unicode strings in C/C++ is not my best field but I'll have a look at this. Obviously the current behavior seems quite undesirable.