-
Notifications
You must be signed in to change notification settings - Fork 90
Open
Description
Expected
cat <<EOF > sample.json | jq .
{
"key": NaN
}
EOF
{
"key": null
}
Actual
cat <<EOF > sample.json | jaq .
{
"key": NaN
}
EOF
Error: failed to parse: value expected
Could you also handle this case? This kind of use case typically occurs when I use Python's default JSON encoder for numpy.nan
values. Example:
uv run --with numpy~=2.3.2 python -c 'import numpy as np; import json; print(json.dumps(np.nan))'
NaN
Metadata
Metadata
Assignees
Labels
No labels