rogchap / wombat

Cross platform gRPC client
MIT License
1.4k stars 52 forks source link

Display binary data as base64 #16

Open ItalyPaleAle opened 3 years ago

ItalyPaleAle commented 3 years ago

When a RPC returns binary data (type bytes), it's currently represented as JSON-encoded UTF-8. However, that is not convenient and it will corrupt messages that aren't valid UTF-8. Suggest representing the data as base64-encoded string instead.

PS: I really <3 this app and it's already been extremely useful to me... and I found it only today :) Thanks!

rogchap commented 3 years ago

Thanks for the suggestion. Will take a look. Thanks for the feedback too; glad it has been useful.

optiman commented 3 years ago

Probably, the easiest would be to just add a selector in the UI to choose response marshaller (Text/JSON), because protojson.encoder encodes bytes to base64 by default.