Skip to content

Cherry-pick: Cherry-pick bug fixes to 8.8 (#1557) - #1578

Merged
AvivDavid23 merged 3 commits into
2.8from
cherry-pick-0b3cc6ea-to-2.8
Apr 26, 2026
Merged

AvivDavid23 merged 3 commits into
2.8from
cherry-pick-0b3cc6ea-to-2.8

Conversation

@AvivDavid23

@AvivDavid23 AvivDavid23 commented Apr 26, 2026 •

Copy link
Copy Markdown
Contributor

Cherry-pick of 0b3cc6e onto 2.8

Includes:

  • MOD-6722 Fix mutation ordering for array commands with recursive paths
  • MOD-7266 make sure to end() deserialization, to disallow trailing content
  • MOD-14664 Json Path evaluation - Allow multi-result nodelists in filter comparisons, Don't evaluate filters on scalar types

Conflict resolutions:

  • json_path/src/json_path.rs: inserted results_to_term helper + updated call sites + removed filter-on-scalar else-if branch
  • redis_json/src/commands.rs: json_arr_insert_legacy uses if/else form so sorting was added inside the else block
  • redis_json/src/ivalue_manager.rs: adapted MOD-7266 to 2.8's IValue::deserialize pattern while adding deserializer.end()

Made with Cursor


Note

Medium Risk
Touches JSONPath filter evaluation and array-mutating command execution order, which can change query results and mutation behavior for recursive paths. Also tightens JSON parsing to reject trailing characters, which may break previously-accepted inputs.

Overview
Fixes JSONPath filter evaluation to follow RFC 9535: filter subqueries that return multiple nodes (e.g. @.*, @..key) are now treated as NodeLists and comparisons/regex succeed if any element matches, and filters no longer run against primitive values (they select nothing).

Ensures array-mutating commands (JSON.ARRPOP, JSON.ARRTRIM, JSON.ARRINSERT, including legacy variants) apply mutations in a safe order for recursive matches (deepest paths first, higher indices first) while preserving the original reply ordering.

Makes JSON.SET/parsing stricter by calling deserializer.end() so inputs with trailing characters are rejected, and expands/updates tests to cover the new behaviors (no duplicate recursive-descent scalar matches, NodeList filter semantics, mutation ordering, and trailing-content rejection).

Reviewed by Cursor Bugbot for commit d069067. Bugbot is set up for automated code reviews on this repo. Configure here.

AvivDavid23 and others added 3 commits April 26, 2026 08:46
* MOD-6722 Fix mutation ordering for array commands with recursive paths (#1543)

* MOD-7266 make sure to `end()` deserialization, to disallow trailing c… (#1554)

* MOD-14664 Json Path evaluation - Allow multi-result nodelists in filt… (#1542)

* MOD-14664 Json Path evaluation - Allow multi-result nodelists in filter comparisons, Don't evaluate filters on scalar types

* MOD-7264 | MOD-7270 fmt

* tests(for coverage)

* Revert "tests(for coverage)"

This reverts commit b0668a5.
Made-with: Cursor
@AvivDavid23
AvivDavid23 merged commit 5268a2b into 2.8 Apr 26, 2026
56 of 57 checks passed
@AvivDavid23
AvivDavid23 deleted the cherry-pick-0b3cc6ea-to-2.8 branch April 26, 2026 11:17
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.

2 participants