cli icon indicating copy to clipboard operation
cli copied to clipboard

"tuya-cli get" produces a json string that does not conform to standard

Open timo12357 opened this issue 2 years ago • 2 comments

When using tuya-cli to read status of zigbee sensors behind a gateway like this:

tuya-cli get --ip 192.168.0.114 --id bf82mostofitremoved --key 322fmostofitremoved --cid a4c1mostofitremoved --protocol-version 3.3

it produces an output like this:

{ '1': 173, '2': 249, '4': 100 }

JSON does only allow double quotes. And so does the JSONPath Online Evaluation.

https://www.json.org/json-en.html#:~:text=wrapped%20in%20double%20quotes

It seems like the tuya-cli output would benefit from using double quotes, too?

timo12357 avatar Feb 02 '23 16:02 timo12357

Yes, happy to accept a PR to fix this.

codetheweb avatar Feb 05 '23 20:02 codetheweb