chime-experiment / chime-experiment/coco

Parameter type checking should allow `int`s where a `float` is required

Open
#176 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
3
Forks
2
PR merge metrics
No merged PRs in 30d

Description

With JSON, it's really easy to end up with an `int` rather than a whole number `float` -- the difference is just in the period, and e.g., `"{:.0f}".format(3.0)` will produce a "3". A number of scripts also exist that were written before the type-checking got stricter and casually send whole numbers, especially "0", in a way that JSON parses as ints, causing Coco to reject them as malformed requests.

Instead, we should have special handling for this case and just convert an int to float silently.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.