← Back to Pull requests

Fix TPC-DS integration tests: handle NULLs in ORDER BY validation #347

Closed
unknown closed this pull request without merging on May 20, 2026 14:44 UTC
View on GitHub
unknown unknown commented on May 18, 2026 14:28 UTC
Author

Summary

  • Fixes 17 TPC-DS integration tests that started failing in presto-nightly #122 with TypeError: '<' not supported between instances of 'str' and 'float' (and float and str, and NoneType and NoneType) — see "Root cause" below.

  • Adds 6 new regression tests covering the failure shapes.

  • Also un-breaks 2 preexisting unit tests in the same file that no longer worked under pandas 3.x (the version pinned in

  • presto/testing/requirements.txt and spark_gluten/testing/requirements.txt).

    After this PR pytest common/testing/result_comparison_test.py is 22/22 green (was 15/17 before this branch, ignoring the new tests).

    Failing job

    presto-nightly run 26017210785, job 76471406344
    — pinned / presto-test / integration-test (tpcds, presto-gpu-cuda13.1, amd64, l4).

    Stack trace, identical for all 17 failures:

    (130 durations < 0.005s hidden.  Use -vv to show these durations.)
    =========================== short test summary info ============================
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q5] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q15] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q20] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q23] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q30] - TypeError: '<' not supported between instances of 'float' and 'str'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q45] - TypeError: '<' not supported between instances of 'float' and 'str'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q46] - TypeError: '<' not supported between instances of 'NoneType' and 'NoneType'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q50] - TypeError: '<' not supported between instances of 'float' and 'str'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q62] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q65] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q66] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q68] - TypeError: '<' not supported between instances of 'NoneType' and 'NoneType'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q77] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q80] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q81] - TypeError: '<' not supported between instances of 'float' and 'str'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q98] - TypeError: '<' not supported between instances of 'str' and 'float'
    FAILED ../testing/integration_tests/tpcds_test.py::test_query[Q99] - TypeError: '<' not supported between instances of 'str' and 'float'
    ============ 17 failed, 49 passed, 16 warnings in 243.74s (0:04:03) ============
    

    Diff: 463 lines (+347 / -116) across 5 files Reviewer: Avinash-Raj Review duration: 2895m
    All Vouch review confidence checks passed
    Residual risk 0.18 = Change Risk (0.46) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.46 · 463 lines diff across 5 files
    0.46
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.367
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #347"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 45.6% (MEDIUM) · Higher = larger blast radius
    45.6%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 18% · Safe to merge
    18%