Repository navigation
Test _shape=arrays and _shape=arrayfirst for rows containing infinity - #3073
Merged
Merged
Conversation
remove_infinites() returns a plain list for a sqlite3.Row that contains infinity. json_renderer() used to assert that every row was a sqlite3.Row or a dict, so those two shapes returned a 500 for such rows. 030d482 (#3005) changed those branches to treat anything that is not a dict as a sequence, which fixed this as a side effect but added no test for it. These tests cover query, table and row pages. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3073 +/- ##
=====================================
Coverage 0.00% 0.00%
=====================================
Files 80 80
Lines 14000 14000
=====================================
Misses 14000 14000 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
Regression tests only. There is no code change, because the bug #2986 set out to fix is already fixed on main.
Claude Fable 5.2 Medium
Background
remove_infinites()returns a plain list for asqlite3.Rowthat contains infinity.json_renderer()used to assert that every row was asqlite3.Rowor a dict, so?_shape=arraysand?_shape=arrayfirstreturned a 500 for those rows.030d482 (#3005) rewrote those two branches to treat anything that is not a dict as a sequence. That fixed the 500 as a side effect, but nothing tests it.
What this adds
test_infinity_with_array_shapesintests/test_table_api.py, covering both shapes on:infinityfixture tableAll six cases pass on current main.
This is the last piece of #2986 that was not already on main or in #3071, so #2986 can be closed.
🤖 Generated with Claude Code