Skip to content

rust: reject nonfinite numeric configuration values #970

Closed

Description

@athvin

Evidence

YAML .nan and .inf parse into f64 and pass configuration normalization and publish checks. canonical_document converts through serde_json::Value, which maps nonfinite floats to JSON null. Distinct invalid numeric values can therefore share a configuration hash and reach the pipeline. Source.

Change

Reject nonfinite numeric fields before hashing, version creation, and publish. Preserve the current canonical representation for finite values.

Done when

  • YAML .nan, .inf, and -.inf in numeric config fields fail with a useful field error.
  • Create and publish paths both reject them.
  • Finite config hashes remain stable and regression tests cover the prior collision.

Activity

  1. added
    code-cleanup
    on Nov 9, 2026
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

    code-cleanup

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions