Skip to content

[fix](regression) Stabilize variant hirachinal array output#63610

Merged
eldenmoon merged 1 commit into
apache:masterfrom
eldenmoon:codex/stabilize-variant-hirachinal-out-master
May 26, 2026
Merged

[fix](regression) Stabilize variant hirachinal array output#63610
eldenmoon merged 1 commit into
apache:masterfrom
eldenmoon:codex/stabilize-variant-hirachinal-out-master

Conversation

@eldenmoon
Copy link
Copy Markdown
Member

What problem does this PR solve?

Issue Number: None

Related PR: None

Problem Summary: Stabilize the variant predefine hirachinal regression output by serializing v['c'] through JSON instead of relying on variant string formatting, which can differ in insignificant array whitespace.

Release note

None

Check List (For Author)

  • Test: Regression test
    • ./run-regression-test.sh --run --conf tmp/regression-conf.auto.groovy -d variant_p0/predefine -s regression_test_variant_predefine_hirachinal -forceGenOut
    • ./run-regression-test.sh --run --conf tmp/regression-conf.auto.groovy -d variant_p0/predefine -s regression_test_variant_predefine_hirachinal
  • Behavior changed: No
  • Does this need documentation: No

### What problem does this PR solve?

Issue Number: None

Related PR: None

Problem Summary: Stabilize the variant predefine hirachinal regression output by serializing v['c'] through JSON instead of relying on variant string formatting, which can differ in insignificant array whitespace.

### Release note

None

### Check List (For Author)

- Test: Regression test
    - ./run-regression-test.sh --run --conf tmp/regression-conf.auto.groovy -d variant_p0/predefine -s regression_test_variant_predefine_hirachinal -forceGenOut
    - ./run-regression-test.sh --run --conf tmp/regression-conf.auto.groovy -d variant_p0/predefine -s regression_test_variant_predefine_hirachinal
- Behavior changed: No
- Does this need documentation: No
@eldenmoon
Copy link
Copy Markdown
Member Author

run buildall

@eldenmoon eldenmoon closed this May 25, 2026
@eldenmoon eldenmoon reopened this May 25, 2026
@eldenmoon
Copy link
Copy Markdown
Member Author

run buildall

@eldenmoon eldenmoon marked this pull request as ready for review May 26, 2026 01:56
Copilot AI review requested due to automatic review settings May 26, 2026 01:56
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Stabilizes the regression output for the “variant hirachinal” predefined test by avoiding Variant-to-string formatting differences (notably insignificant whitespace in arrays) and instead serializing v['c'] via JSON.

Changes:

  • Update regression queries to use cast(v['c'] as json) instead of cast(v['c'] as string).
  • Regenerate the expected .out file to reflect the stable JSON serialization output (e.g., [1,2,3]).

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.

File Description
regression-test/suites/variant_p0/predefine/variant_hirachinal.groovy Switches v['c'] serialization in test queries from string formatting to JSON casting for stable output.
regression-test/data/variant_p0/predefine/variant_hirachinal.out Updates expected results to match JSON serialization formatting (removes array whitespace variance).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +39 to +40
order_qt_sql1 "select cast(v['c'] as json) from var_rs where k = -3 or k = -2 or k = -4 or (k = 1 and v['c'] = 1024) order by k"
order_qt_sql2 "select cast(v['c'] as json) from var_rs where k = -3 or k = -2 or k = 1 order by k, cast(v['c'] as text) limit 3"
@github-actions github-actions Bot added the approved Indicates a PR has been approved by one committer. label May 26, 2026
@github-actions
Copy link
Copy Markdown
Contributor

PR approved by at least one committer and no changes requested.

@github-actions
Copy link
Copy Markdown
Contributor

PR approved by anyone and no changes requested.

@eldenmoon
Copy link
Copy Markdown
Member Author

/review

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review conclusion: no additional blocking issues found in this PR. The diff is narrowly scoped to stabilizing one variant regression query by casting the selected sub-value to JSON and updating the generated expected output accordingly. I did not duplicate the already-open inline thread about using var_rs instead of ${table_name}.

Critical checkpoint conclusions:

  • Goal/test proof: The stated goal is to avoid insignificant variant string-format whitespace differences in regression_test_variant_predefine_hirachinal; the query/output changes match that goal, and the PR reports both force-generating and rerunning the focused regression test. CI regression checks are passing.
  • Scope/focus: The change is small and limited to the affected regression suite and .out file.
  • Concurrency/lifecycle/config/compatibility/persistence/data-write concerns: Not applicable; this is regression test SQL/output only.
  • Parallel paths: Similar variant hierarchy suites still use string casts, but this PR targets the predefine suite output instability specifically; no distinct correctness issue found from that alone.
  • Test coverage/results: The expected output is consistent with JSON serialization for the changed query. No additional user-provided focus points were present.
  • Observability/performance: Not applicable for this test-only change.

@eldenmoon eldenmoon merged commit eb46d1e into apache:master May 26, 2026
56 checks passed
github-actions Bot pushed a commit that referenced this pull request May 26, 2026
Stabilize the variant predefine hirachinal regression
output by serializing `v['c']` through JSON instead of relying on
variant string formatting, which can differ in insignificant array
whitespace.
github-actions Bot pushed a commit that referenced this pull request May 26, 2026
Stabilize the variant predefine hirachinal regression
output by serializing `v['c']` through JSON instead of relying on
variant string formatting, which can differ in insignificant array
whitespace.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. dev/3.0.x dev/4.0.x dev/4.1.x reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants