Closed guidanoli closed 4 months ago
On a recent discussion in the #machine Discord channel, it came to my attention the existence of a JSON RPC discovery file.
#machine
I expected this JSON file to be well-formed.
This JSON file contains a trailing comma at line 1651.
https://github.com/cartesi/machine-emulator/blob/67ee8ea521e687b2b8846f0189e6121eec63d146/src/jsonrpc-discover.json#L1649-L1652
cat src/jsonrpc-discover.json | jq
You should see the following error:
parse error: Expected another key-value pair at line 1652, column 9
Tested with jq version 1.6.
jq
Remove the trailing comma.
Context
On a recent discussion in the
#machine
Discord channel, it came to my attention the existence of a JSON RPC discovery file.Expected behavior
I expected this JSON file to be well-formed.
Actual behavior
This JSON file contains a trailing comma at line 1651.
https://github.com/cartesi/machine-emulator/blob/67ee8ea521e687b2b8846f0189e6121eec63d146/src/jsonrpc-discover.json#L1649-L1652
Steps to reproduce
You should see the following error:
Tested with
jq
version 1.6.Environment
Possible solutions
Remove the trailing comma.