Junk value displayed when char '>' is present in response value
In the current scenario the exact value of parameter is "*> il", but '>' is displayed as \u003e in gnmic.
-
Value includes few special chars like *, >, and space char. Facing display issue with '>' only.
-
Is there any restriction at gnmic wrt the usage of special chars ?
-
This value is displayed correctly in a C++ based gRPC client.
{ "address": "1.2.3.4", "key1": "i", "key2": "Local", "key3": "*\u003e il", . . . }
That is expected, it is Go's encoding/json package default behavior.
It escapes >, < and & for security reasons.
You could convert back the unicode character before using the value or I can add a flag to disable escaping those chars. Which command and encoding do you see/need this ?
Adding a flag would surely help
- I observed this with GET & JSON+ASCII encoding.
- Checking for subscribe too