Skip to content

Backport Test Stability Fixes to 7.2#3524

Closed
sarthakaggarwal97 wants to merge 8 commits intovalkey-io:7.2from
sarthakaggarwal97:backport-test-fixes-7.2
Closed

Backport Test Stability Fixes to 7.2#3524
sarthakaggarwal97 wants to merge 8 commits intovalkey-io:7.2from
sarthakaggarwal97:backport-test-fixes-7.2

Conversation

@sarthakaggarwal97
Copy link
Copy Markdown
Contributor

@sarthakaggarwal97 sarthakaggarwal97 commented Apr 16, 2026

Backports and targeted fixes for flaky tests on 7.2.

Weekly CI context: https://github.com/valkey-io/valkey/actions/runs/24300553351

Partial cherry-pick of f3b6470 from unstable.
Only maxmemory.tcl and memefficiency.tcl apply to 7.2.
Adapted: valkey_deferring_client -> redis_deferring_client.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
Cherry-pick of c35dbdf from unstable.
Adapted: valkey_deferring_client -> redis_deferring_client.
Note: diskless-load-swapdb.tcl is at tests/cluster/tests/ on 7.2
(moved to tests/unit/cluster/ on later branches).

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
Fedora Rawhide/Latest now ships Tcl 9.x. The runtest scripts only
looked for tclsh8.5/8.6/8.7, causing 'You need tcl 8.5 or newer'
failures on Fedora CI jobs.

Minimal backport of the Tcl version detection from valkey-io#1673.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
The weekly CI workflow uses unstable's daily.yml which passes
--io-threads to the test runner. 7.2's test_helper.tcl didn't
recognize this flag, causing 'Wrong argument: --io-threads' failures.

Translates --io-threads to --config io-threads 4 --config
io-threads-do-reads yes, matching the behavior on newer branches.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
Replace (void (*)(void*))sdsfree casts with sdsfreeVoid (which already
exists on 7.2 in sds.c). Add engineLibraryFreeVoid wrapper in
functions.c. Remove unnecessary cast on zfree (already void*).

Fixes UBSan error: 'call to function sdsfree through pointer to
incorrect function type void (*)(void *)' at adlist.c:185.

Minimal backport of valkey-io#1451 from unstable.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
Port the robust version of 'client evicted due to percentage of
maxmemory' from unstable. The 7.2 version was racy — it asserted
memory usage immediately after write+flush without waiting for the
query buffer to be populated. Under TLS or ASAN overhead, the data
hadn't arrived yet, causing assertion failures.

Changes from unstable:
- Send n-1 bytes (not n) to avoid using the shared query buffer
- Add wait_for_condition before asserting tot-mem
- Add wait_for_condition in the eviction path too

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
@sarthakaggarwal97 sarthakaggarwal97 force-pushed the backport-test-fixes-7.2 branch from 5bdfe08 to b75c6f9 Compare April 16, 2026 20:49
Use CLIENT REPLY OFF pattern in the defrag eval scripts test which
pipelines 50,000 script loads + 50,000 set commands. Without this,
the TCP send buffer fills up causing 'I/O error reading reply'.

Same CLIENT REPLY OFF pattern as valkey-io#3430 and valkey-io#3452.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
Cherry-pick of 6ce75cd from unstable.

Signed-off-by: Sarthak Aggarwal <sarthagg@amazon.com>
@sarthakaggarwal97
Copy link
Copy Markdown
Contributor Author

Closing because it's quite unstable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant