fix(cubestore): advertise INCR, not INC, in the CACHE unknown-command error - #11434
Conversation
|
Claude finished @igorlukanin's task in 1m 34s —— View job Review complete — approve; 0 high, 0 medium, 1 low (1 inline comment)Full review
VerdictThe fix is correct and minimal. Test correctnessI traced the message-extraction path by hand since I couldn't run
Asserting the property rather than the literal string is the right call here, and the red-check against three wrong implementations described in the PR body is the part that makes it credible. Low: coverage is one-directionalPosted inline at the Other areasNothing to report on security (no input-handling change; this is an error string on an already-rejected statement), performance (cold error path, CaveatI could not execute |
Codecov Report✅ All modified and coverable lines are covered by tests.
Additional details and impacted files@@ Coverage Diff @@
## master #11434 +/- ##
===========================================
- Coverage 83.95% 59.00% -24.96%
===========================================
Files 257 223 -34
Lines 80887 17891 -62996
Branches 0 3636 +3636
===========================================
- Hits 67908 10556 -57352
+ Misses 12979 6817 -6162
- Partials 0 518 +518
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
c6cbea3 to
f998ed0
Compare
|
Claude finished @igorlukanin's task in 47s —— View job Review complete — approve; 0 high, 0 medium, 0 low (no inline comments)Full review
What changed since the last reviewThe PR is now the single-line string fix only — the property test that my earlier comment discussed has been dropped, per @igorlukanin's "Don't add a new test, the fix above is enough." Diff is exactly VerdictCorrect and minimal. Skipping tests is a reasonable call here — the string is user-visible only on an already-rejected statement, and a test asserting it would either be a tautology on the literal text or reintroduce the one-directional coverage gap I flagged before. The trade-off is that nothing mechanically prevents the same drift if a seventh arm is added later; that's the author's call and I'm not re-raising it. Other areas
Prior threadsBoth existing threads on this file (my CaveatI could not run |
Issue
The
CACHEcommand parser acceptsincr, but the error it emits for an unknown subcommand advertisesINC— a keyword that doesn't parse. An operator who follows the error message gets a second error:The accepted set is exactly
SET|GET|KEYS|INCR|REMOVE|CLEAR, soINCis the only inaccurate entry. This is the only enumerated-keyword error message in the parser — the other unknown-command arms emit a bare "Unknown … command" with no list.Description of Change
Corrects the advertised keyword to
INCR.