Repository navigation
fix: render 0-d integer and bool arrays as integer and checkbox inputs - #199
Open
singhharsh1708 wants to merge 1 commit into
Open
singhharsh1708 wants to merge 1 commit into
singhharsh1708 wants to merge 1 commit into
Conversation
singhharsh1708
requested review from
apaleyes,
dionhaefner and
jacanchaplais
as code owners
November 3, 2026 18:54
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #199 +/- ##
==========================================
+ Coverage 86.64% 86.96% +0.32%
==========================================
Files 5 5
Lines 322 330 +8
Branches 36 39 +3
==========================================
+ Hits 279 287 +8
Misses 39 39
Partials 4 4 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relevant issue or PR
Follows #198.
Description of changes
A 0-d array input was always rendered as a float
number_input, whatever its dtype. For anInt32orArray[(), "bool"]field the app then sent3.0, and the Tesseract rejected it withArray dtype 'float64' cannot be safely cast to 'int32'(or'bool'). The field type now follows the declared dtype in the schema'sdtype.examples: integers get the integer input and booleans a checkbox. The integer input also needed a step of 1 when nomultipleOfis set, since itsget("step", 1)fallback never applied (the key is always present, asNone).Testing done
Int32,Float32and bool 0-d inputs, run against it served withtesseract-runtime serve: the request fails validation on main; here it returns{"result": 6.0}.tests/test_parse.pypasses excepttest_description_from_oas, which builds a Docker image and fails the same way on main without Docker.