Repository navigation
Preserve RLTest diagnostics and retry setup across runner modes - #806
Conversation
|
🤖 Automated first-pass review — a human maintainer's review is still required before merge. Thanks, this is a nice harness cleanup. The One question on the retry side. I may be wrong about this, but I don't think saved = {k.decode() if isinstance(k, bytes) else k: v
for k, v in conn.config_get("maxmemory*").items()}The same applies to all four sites. Nitpicking: the trailing-newline fix in Otherwise this looks good to me. I'd just like the RESP2 restore question settled before it merges. (would file this as a comment, not a formal block) |
|
The initial oss control established that the test passed and CONFIG keys had the expected shape; its restoration flag queried the separate existing-env server. I added an actual oss/RESP2 restoration check to settle this directly: set In installed redis-py 8.1.0, the RESP2 CONFIG GET callback is Reproducible oss witness and output: https://github.com/redis-performance/memtier-agent-workspace/tree/main/.workspace-memory/reviews/806-owner-evidence/oss-restoration . All tests use owned authenticated servers, and the deliberate diagnostic assertions remain failures. No source change was needed for this check. |
|
The portability review is complete too: actual authenticated Redis controls passed for redis-py 3.0.0 and 3.5.3 on Python 3.10 with both decoding settings, and 8.1.0 on Python 3.14 with RESP2/RESP3 and both settings (8/8). Each control changed maxmemory and eviction policy, then used the unchanged string-key restoration loop and verified the original values. The historical RESP2 callbacks also explicitly apply Evidence: https://github.com/redis-performance/memtier-agent-workspace/blob/main/.workspace-memory/reviews/806-build.md . All seven independent reviews now approve the unchanged head; full CI remains a merge gate. |
Picks up #812, the reconnect deadline-clock fix for the never-started client test that failed this branch's plaintext job, plus #828, #838 and #841. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Problem
RLTest failure diagnostics raise a second exception under existing-env or -s because those modes do not provide a captured Redis log. Four retry tests also slice CONFIG GET replies as flat lists, which crashes with redis-py's RESP3 dictionary replies before memtier runs.
Root cause
The diagnostic helper assumes every runner owns dbDirPath, _getFileName and a readable UTF-8 log. Retry setup assumes the raw RESP2 CONFIG representation instead of using redis-py's normalized API.
Fix
Check the runner's log capabilities, report unavailable logs without replacing the original assertion, tolerate filesystem read errors and replace invalid diagnostic bytes. Keep ordinary captured log output and the cluster path intact. Use config_get("maxmemory*") at all four retry setup sites, preserving the existing configuration restoration.
No benchmark production code, protocol choice or workload assertions change.
Tests
Affected versions
The unguarded Redis-log read was introduced by c9278c0 (#114), affecting 1.3.0–2.5.2 and master. 82dba6a (#207) moved it into the shared failure helper in 2.0.0.
The CONFIG slicing is unreleased master only: introduced by 1c6f7c4 and 50cfd7f through #559, with two later sites from bc7320a (#700) and cde91ea (#724). Source/tag attribution is historical; actual paired execution uses current master 6818fe3 and pinned RLTest with Python 3.14/redis-py 8.1.0. Product binaries are unaffected.
Fixes #641.
🤖 Generated with Claude Code
Note
Low Risk
Test harness and diagnostic helpers only; no memtier binary or production benchmark behavior changes.
Overview
Hardens RLTest failure diagnostics so memtier assertion failures no longer trigger a second exception when Redis logs are missing or unreadable (existing-env,
-s, or partial runners). Cluster mode still skips log printing; when a captured log exists, output is read witherrors="replace"andOSErroris reported without masking the original assertion.Fixes retry-on-error test setup by replacing raw
CONFIG GETlist slicing withconn.config_get("maxmemory*")in four OOM scenarios, so setup works with redis-py RESP3 dict replies.Adds
test_harness_diagnostics.pywith three regressions that exercise the realassert_minimum_memtier_outcomesfinally path (no managed log, missing/unreadable log, non-UTF-8 log bytes). Minor whitespace fix inget_column_csv.Reviewed by Cursor Bugbot for commit fa85d68. Bugbot is set up for automated code reviews on this repo. Configure here.