Skip to content

bug(api): NaN/Inf render as null on /v1/query but as "nan"/"inf" strings on the stream #722

Description

@EricAndrechek

Found while documenting the type layer in draft PR #712 (branch chtypes-v2).

Problem. Float NaN and +-Inf render as null on /v1/query and pipes, and as the strings "nan", "inf", "-inf" on the stream. A live query can mix the two. Measured on a ClickHouse 26.8 build: the chtypes export ignored output_format_json_quote_denormals whether it was 0, 1 or unset, and returned no unsupported-setting error.

The server also accepts "nan"/"inf" strings on insert (stored as nan/inf), while null stores 0 or NULL (measured), so pinning the setting alone would not make the surfaces round-trip.

Related: #365 (pipes NaN/Inf serialisation).

Waiting on: chtypes honouring the setting in its export (tracked upstream in chtypes). Today documented as-is in sdk/reference.md and api.md, with a test pinning the stream spelling.

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions