Skip to content

Conversation

@arin-mirza
Copy link
Contributor

@arin-mirza arin-mirza commented Nov 28, 2025

Why I'm doing:

I recently added E2E SQL test cases for testing the mem_pool property.

One of the test cases has an incorrect regex.

show verbose resource groups all;
-- result:
[REGEX][^shared_resource_group_for_brad]
-- !result

The intention was to assert that the expression cannot be matched in the result.
It instead tries to match a single character that is not present in the brackets.
The correct regex should use a negative lookahead to implement the intended behavior.

The test case, however, does not fail, as the result coincidentally does not start with any of these characters.

What I'm doing:

The check is actually redundant, as we already assert that the resource group was not created in the previous check.
Instead of adding another complicated regex with negative lookaheads, I am simply removing it.

Fixes #issue

What type of PR is this:

  • BugFix
  • Feature
  • Enhancement
  • Refactor
  • UT
  • Doc
  • Tool

Does this PR entail a change in behavior?

  • Yes, this PR will result in a change in behavior.
  • No, this PR will not result in a change in behavior.

If yes, please specify the type of change:

  • Interface/UI changes: syntax, type conversion, expression evaluation, display information
  • Parameter changes: default values, similar parameters but with different default values
  • Policy changes: use new policy to replace old one, functionality automatically enabled
  • Feature removed
  • Miscellaneous: upgrade & downgrade compatibility, etc.

Checklist:

  • I have added test cases for my bug fix or my new feature
  • This pr needs user documentation (for new or modified features or behaviors)
    • I have added documentation for my new feature or new function
  • This is a backport pr

Bugfix cherry-pick branch check:

  • I have checked the version labels which the pr will be auto-backported to the target branch
    • 4.0
    • 3.5
    • 3.4
    • 3.3

Note

Removes an incorrect regex-based assertion and a duplicate show verbose resource groups all call from the mem_pool resource group test.

  • Tests (SQL mem_pool resource groups):
    • Remove invalid regex assertion block from R/test_create_two_resource_groups_with_mem_pool_different_mem_limit that attempted to verify absence in show verbose resource groups all output.
    • Simplify T/test_create_two_resource_groups_with_mem_pool_different_mem_limit by removing a duplicate show verbose resource groups all call, leaving a single invocation.

Written by Cursor Bugbot for commit eef6213. This will update automatically on new commits. Configure here.

@arin-mirza arin-mirza changed the title Remove potentially buggy SQL test case for mem_pool property of resource groups [BugFix] Remove potentially buggy SQL test case for mem_pool property of resource groups Nov 28, 2025
@arin-mirza arin-mirza force-pushed the rg-memory-pool-e2e-sql-test-small-fix branch from 0e32622 to 712eeb3 Compare November 28, 2025 11:35
@arin-mirza
Copy link
Contributor Author

The failing test case seems to be unrelated to my changes.

----------------------------------------------------------------------
XML: nosetests.xml
----------------------------------------------------------------------
Ran 1063 tests in 627.714s

FAILED (failures=1)
⌛️ Time spent:
👉🏻 UNSTABLE SQL TEST: 1
info: sql/test_alter_table/R/test_schema_change_and_insert_concurrent@test_schema_change_and_insert_concurrent
ERROR LOGFILE: 
test_schema_change_and_insert_concurrent.log
current_version()
main-3d0d09d
❌ Unstable case: sql/test_alter_table/R/test_schema_change_and_insert_concurrent@test_schema_change_and_insert_concurrent
Updated case to db: sql/test_alter_table/R/test_schema_change_and_insert_concurrent@test_schema_change_and_insert_concurrent (Namespace: unstable_case)
---------------------------------------------------------------------
Type: SQL-Tester
Name: sql/test_alter_table/R/test_schema_change_and_insert_concurrent@test_schema_change_and_insert_concurrent
URL: https://github.com/StarRocks/starrocks/actions/runs/19762687694/attempts/1
Time: 2025-11-28 20:39:53
Branch: main
Repo: StarRocks/starrocks
Delete historical records...
Upload info to oss...
Error: Process completed with exit code 1.

@alvin-celerdata
Copy link
Contributor

@mergify rebase

@mergify
Copy link
Contributor

mergify bot commented Nov 28, 2025

rebase

☑️ Nothing to do, the required conditions are not met

Details
  • any of:
    • #commits > 1 [📌 rebase requirement]
    • #commits-behind > 0 [📌 rebase requirement]
    • -linear-history [📌 rebase requirement]
  • -closed [📌 rebase requirement]
  • -conflict [📌 rebase requirement]
  • queue-position = -1 [📌 rebase requirement]

@alvin-celerdata alvin-celerdata changed the title [BugFix] Remove potentially buggy SQL test case for mem_pool property of resource groups [UT] Remove potentially buggy SQL test case for mem_pool property of resource groups Nov 28, 2025
@alvin-celerdata
Copy link
Contributor

@cursor review

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bug: T file not updated to match R file changes

The R (result) file had a show verbose resource groups all; command and its result block removed, but the corresponding T (template) file at test/sql/test_resource_group_mem_pool/T/test_create_two_resource_groups_with_mem_pool_different_mem_limit still contains two show verbose resource groups all; commands at lines 22-23. This creates a mismatch where the T file expects two executions of this command but the R file only defines expected results for one, which will likely cause test failures or incorrect test behavior.

test/sql/test_resource_group_mem_pool/R/test_create_two_resource_groups_with_mem_pool_different_mem_limit#L24-L28

show verbose resource groups all;
-- result:
[REGEX]shared_resource_group_for_alex.+7.+55(\.\d+)?%.+NORMAL.+\(id=\d+,.+user=alex\)\s*(shared_pool_for_alex_and_brad)
-- !result

Fix in Cursor Fix in Web


@mergify
Copy link
Contributor

mergify bot commented Dec 9, 2025

🧪 CI Insights

Here's what we observed from your CI run for eef6213.

🟢 All jobs passed!

But CI Insights is watching 👀

@arin-mirza arin-mirza force-pushed the rg-memory-pool-e2e-sql-test-small-fix branch from f6c99e1 to eef6213 Compare December 9, 2025 12:22
@github-actions
Copy link
Contributor

github-actions bot commented Dec 9, 2025

[Java-Extensions Incremental Coverage Report]

pass : 0 / 0 (0%)

@github-actions
Copy link
Contributor

github-actions bot commented Dec 9, 2025

[FE Incremental Coverage Report]

pass : 0 / 0 (0%)

@github-actions
Copy link
Contributor

github-actions bot commented Dec 9, 2025

[BE Incremental Coverage Report]

pass : 0 / 0 (0%)

@alvin-celerdata
Copy link
Contributor

@cursor review

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

✅ Bugbot reviewed your changes and found no bugs!


@alvin-celerdata alvin-celerdata merged commit d36d837 into StarRocks:main Dec 9, 2025
65 checks passed
@github-actions
Copy link
Contributor

github-actions bot commented Dec 9, 2025

@Mergifyio backport branch-4.0

@github-actions github-actions bot removed the 4.0 label Dec 9, 2025
@mergify
Copy link
Contributor

mergify bot commented Dec 9, 2025

backport branch-4.0

✅ Backports have been created

Details

mergify bot pushed a commit that referenced this pull request Dec 9, 2025
…resource groups (#66104)

Signed-off-by: arin-mirza <[email protected]>
(cherry picked from commit d36d837)
@chelseaw0
Copy link

ignore backport check: 4.0.3

wanpengfei-git pushed a commit that referenced this pull request Dec 9, 2025
…resource groups (backport #66104) (#66531)

Signed-off-by: arin-mirza <[email protected]>
Co-authored-by: Arın Mirza <[email protected]>
EdwardArchive pushed a commit to EdwardArchive/starrocks that referenced this pull request Dec 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants