Skip to content

fix(oc-path): descend into JSONL line values when ** spans the line slot - #189960

Merged
obviyus merged 4 commits into
openclaw:mainfrom
jerome-queck:fix/oc-path-jsonl-globstar
Nov 1, 2026
Merged

obviyus merged 4 commits into
openclaw:mainfrom
jerome-queck:fix/oc-path-jsonl-globstar

Conversation

@jerome-queck

@jerome-queck jerome-queck commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #189957

What Problem This Solves

openclaw path find 'oc://session.jsonl/**/event' misses values nested inside a JSONL record, even though an explicit line selector followed by recursive descent finds them. Bare ** also omits nested values.

User Impact

Recursive JSONL searches now return the matching nested values with valid, reusable physical-line addresses. Existing non-recursive searches and JSON/YAML recursion are unchanged.

Why This Change Was Made

The existing recursive walker consumes both the line address and JSON keys, but its slot packer groups them into a section such as L2.nest.deep. JSONL resolution requires the section to contain only the line address, so the final resolver drops the match.

Repair that producer: keep the line selector in the section and move consumed keys into the available value slots, preserving existing slot/depth limits and resolver validation. The format-local helper avoids copying on unchanged paths. No new syntax, setting, public API or fallback. Existing docs already define zero-or-more recursive ** and JSONL descent inside each line.

@jerome-queck's commits, including the latest regression cleanup, are preserved. Regression coverage is consolidated into an existing table; its helper already round-trips every result. Whole-change delta: production+17/-1, tests+3/-3(net0), docs+2; no allocation increase.

Evidence

Independent canonical runtime builds in secretless Linux Docker/Node24.22.1; real shipped CLI, enabled built plugin and isolated profile/config/state/workspaces. Twice on frozen main, nested **/event returns count0/exit1 and bare ** returns only3 roots/line nodes. Twice on candidate, the nested match returns count1/exit0 and bare recursion returns all7 results. Every candidate address resolves through the real CLI. Non-recursive JSONL, JSON/YAML recursive controls and a size-bounded depth32 case pass; files remain unchanged.

Committed finder regression:2 intended failures/88passes on main; candidate finder/YAML suites130passed/2files, including expansion-budget and deep-path cases. Targeted lint/format pass. Captured raw CLI output and exact source hashes.

Merge Danger

Two-way door: reverting restores missing recursive JSONL results; no persisted-state migration or write behavior change. Blast radius is JSONL recursive find output and its document-preorder enumeration. Newly valid results can appear earlier than previously discarded traversal routes. Non-recursive selection, physical-line identity, existing capacity checks and JSON/YAML behavior remain intact.

@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review in progress

ClawSweeper is reviewing this revision. This supersedes any previous blocked status.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added extensions: oc-path size: XS triage: needs-pr-context Candidate: external PR body lacks required problem context or evidence. labels Nov 1, 2026
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 1, 2026
@obviyus

obviyus commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@openclaw-barnacle openclaw-barnacle Bot removed the triage: needs-pr-context Candidate: external PR body lacks required problem context or evidence. label Nov 1, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 1, 2026
@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR separates JSONL physical-line addresses from nested keys when packing recursive search results.

Example: session.jsonl contains {"id":"x"} on line 1 and {"nest":{"deep":{"event":"y"}}} on line 2.

  • Before: Searching oc://session.jsonl/**/event returns zero matches and exits 1.
  • After: The search returns y at oc://session.jsonl/L2/nest.deep/event and exits 0.

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) Focused contract repair with exact-head shipped CLI proof, meaningful consolidated regressions, and no actionable findings; remaining CI has not finished.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (terminal): The full obviyus comment supplies exact-head CLI traces from isolated Linux Docker with the built oc-path plugin: nested matching succeeds, bare recursion includes nested values, every returned address resolves, sibling controls pass, and input files remain byte-identical.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Recursive JSONL searches report no nested matches despite documented recursive descent and matching explicit-line searches.
Reason: The change restores an existing contract without new syntax, configuration, public API, or persisted state.

Merge readiness

✅ Ready for maintainer review

Keep this PR: it fixes a current JSONL search defect with a focused repair and convincing CLI evidence; no actionable findings remain, and CI is still running.

Priority: P2
Reviewed head: ff0b739567897228980dc2c4d1b34597d20b7a57

Before merge

None.

Findings

None.

Agent review details

How this fits together

The optional bundled oc-path plugin parses CLI search patterns, walks file ASTs, packs concrete addresses, and validates them through the existing resolver before returning matches.

flowchart TD
  A[CLI search pattern] --> B[Parsed path and file AST]
  B --> C[Recursive finder]
  C --> D[JSONL address packing]
  D --> E[Existing resolver validation]
  E --> F[Concrete paths and values]
Loading

Technical review

Best possible solution:

Land the focused address-packing repair once the existing checks pass.

Do we have a high-confidence way to reproduce the issue?

Current-main source exposes the invalid section-packing path, and supplied paired CLI output demonstrates the same failure on frozen main and success on the exact candidate; no target code was executed during this review.

Is this the best way to solve the issue?

This is the smallest complete repair: normalize JSONL output at the existing packing boundary while preserving resolver validation, capacity limits, and other formats.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against ac227c0bdccc.

Provenance checked

  • Recursive result packing keeps the original intent (5b022ac: Produce distinct, reusable recursive paths with zero-width matching and bounded slot packing.)
  • JSONL physical-line selection keeps the original intent (e242107: Share the existing selection owner while preserving physical-line reads, positional behavior, and edit guards.)
  • Finder regression consolidation keeps the original intent (98dcd36: Consolidate repeated fixtures and assertions while retaining owning-boundary coverage.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

Likely related people:

  • Zhiqi Zhang: Raw commit 5b022ac adds extensions/oc-path/src/oc-path/find.ts:140 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 5b022ac2404d; files: extensions/oc-path/src/oc-path/find.ts)
  • Vincent Koc: Raw commit e242107 adds extensions/oc-path/src/oc-path/jsonl/line.ts:12 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: e2421070c5dd; files: extensions/oc-path/src/oc-path/jsonl/line.ts)
  • Jerome: Raw commit 7f593b6 adds extensions/oc-path/src/oc-path/find.ts:317 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 7f593b69e7ab; files: extensions/oc-path/src/oc-path/find.ts)

PR surface

Source +16, Tests 0, Docs +2. Total +18 across 4 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 2 17 1 +16
Tests 1 3 3 0
Docs 1 2 0 +2
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 4 22 4 +18

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Recursive JSONL searches silently omit valid nested matches in an optional CLI plugin, with explicit-line searches providing a workaround.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (2 earlier review cycles)
  • reviewed 2026-11-01T02:31:57.994Z sha d5cac7e :: needs real behavior proof before merge. :: none
  • reviewed 2026-11-01T02:40:09.767Z sha 5597f11 :: needs maintainer review before merge. :: none

Reviewed October 31, 2026, 10:49 PM ET / November 1, 2026, 02:49 UTC (Revision 3).

@jerome-queck

Copy link
Copy Markdown
Contributor Author

Added captured before/after CLI output (nested **/event and bare **, with paths and exit status) to the Evidence section, and dropped the redundant round-trip loop.

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Nov 1, 2026
@obviyus

obviyus commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator

Independent shipped CLI proof

Exact candidate ff0b739567897228980dc2c4d1b34597d20b7a57; independently frozen main 1f4a08f7925f2a7267fe9e1a69dccb6d53428830. Secretless Linux Docker, Node24.22.1, canonical runtime builds; enabled built oc-path plugin with isolated explicit profiles/config/state/workspaces.

Existing documented syntax: docs/cli/path.md defines ** as zero-or-more recursive subsegments and JSONL line addresses followed by descent inside line values. No new syntax. Fixture:

{"id":"x"}
{"nest":{"deep":{"event":"y"}}}

Captured commands and raw CLI stdout (only synthetic paths/data):

base1

$ openclaw path find oc://session.jsonl/**/event --json
{
  "pattern": "oc://session.jsonl/**/event",
  "count": 0,
  "matches": []
}
[exit 1]
$ openclaw path find oc://session.jsonl/** --json
{
  "pattern": "oc://session.jsonl/**",
  "count": 3,
  "matches": [
    {
      "path": "oc://session.jsonl",
      "match": {
        "kind": "root",
        "ast": {
          "kind": "jsonl",
          "raw": "{\"id\":\"x\"}\n{\"nest\":{\"deep\":{\"event\":\"y\"}}}\n",
          "lines": [
            {
              "kind": "value",
              "line": 1,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "id",
                    "line": 1,
                    "value": {
                      "kind": "string",
                      "value": "x",
                      "line": 1
                    }
                  }
                ]
              },
              "raw": "{\"id\":\"x\"}"
            },
            {
              "kind": "value",
              "line": 2,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "nest",
                    "line": 1,
                    "value": {
                      "kind": "object",
                      "line": 1,
                      "entries": [
                        {
                          "key": "deep",
                          "line": 1,
                          "value": {
                            "kind": "object",
                            "line": 1,
                            "entries": [
                              {
                                "key": "event",
                                "line": 1,
                                "value": {
                                  "kind": "string",
                                  "value": "y",
                                  "line": 1
                                }
                              }
                            ]
                          }
                        }
                      ]
                    }
                  }
                ]
              },
              "raw": "{\"nest\":{\"deep\":{\"event\":\"y\"}}}"
            }
          ],
          "lineEnding": "\n"
        },
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L2",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 2
      }
    }
  ]
}
[exit 0]

base2

$ openclaw path find oc://session.jsonl/**/event --json
{
  "pattern": "oc://session.jsonl/**/event",
  "count": 0,
  "matches": []
}
[exit 1]
$ openclaw path find oc://session.jsonl/** --json
{
  "pattern": "oc://session.jsonl/**",
  "count": 3,
  "matches": [
    {
      "path": "oc://session.jsonl",
      "match": {
        "kind": "root",
        "ast": {
          "kind": "jsonl",
          "raw": "{\"id\":\"x\"}\n{\"nest\":{\"deep\":{\"event\":\"y\"}}}\n",
          "lines": [
            {
              "kind": "value",
              "line": 1,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "id",
                    "line": 1,
                    "value": {
                      "kind": "string",
                      "value": "x",
                      "line": 1
                    }
                  }
                ]
              },
              "raw": "{\"id\":\"x\"}"
            },
            {
              "kind": "value",
              "line": 2,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "nest",
                    "line": 1,
                    "value": {
                      "kind": "object",
                      "line": 1,
                      "entries": [
                        {
                          "key": "deep",
                          "line": 1,
                          "value": {
                            "kind": "object",
                            "line": 1,
                            "entries": [
                              {
                                "key": "event",
                                "line": 1,
                                "value": {
                                  "kind": "string",
                                  "value": "y",
                                  "line": 1
                                }
                              }
                            ]
                          }
                        }
                      ]
                    }
                  }
                ]
              },
              "raw": "{\"nest\":{\"deep\":{\"event\":\"y\"}}}"
            }
          ],
          "lineEnding": "\n"
        },
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L2",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 2
      }
    }
  ]
}
[exit 0]

candidate1

$ openclaw path find oc://session.jsonl/**/event --json
{
  "pattern": "oc://session.jsonl/**/event",
  "count": 1,
  "matches": [
    {
      "path": "oc://session.jsonl/L2/nest.deep/event",
      "match": {
        "kind": "leaf",
        "valueText": "y",
        "leafType": "string",
        "line": 2
      }
    }
  ]
}
[exit 0]
$ openclaw path find oc://session.jsonl/** --json
{
  "pattern": "oc://session.jsonl/**",
  "count": 7,
  "matches": [
    {
      "path": "oc://session.jsonl",
      "match": {
        "kind": "root",
        "ast": {
          "kind": "jsonl",
          "raw": "{\"id\":\"x\"}\n{\"nest\":{\"deep\":{\"event\":\"y\"}}}\n",
          "lines": [
            {
              "kind": "value",
              "line": 1,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "id",
                    "line": 1,
                    "value": {
                      "kind": "string",
                      "value": "x",
                      "line": 1
                    }
                  }
                ]
              },
              "raw": "{\"id\":\"x\"}"
            },
            {
              "kind": "value",
              "line": 2,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "nest",
                    "line": 1,
                    "value": {
                      "kind": "object",
                      "line": 1,
                      "entries": [
                        {
                          "key": "deep",
                          "line": 1,
                          "value": {
                            "kind": "object",
                            "line": 1,
                            "entries": [
                              {
                                "key": "event",
                                "line": 1,
                                "value": {
                                  "kind": "string",
                                  "value": "y",
                                  "line": 1
                                }
                              }
                            ]
                          }
                        }
                      ]
                    }
                  }
                ]
              },
              "raw": "{\"nest\":{\"deep\":{\"event\":\"y\"}}}"
            }
          ],
          "lineEnding": "\n"
        },
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1/id",
      "match": {
        "kind": "leaf",
        "valueText": "x",
        "leafType": "string",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L2",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest",
      "match": {
        "kind": "node",
        "descriptor": "jsonc-object",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest.deep",
      "match": {
        "kind": "node",
        "descriptor": "jsonc-object",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest.deep.event",
      "match": {
        "kind": "leaf",
        "valueText": "y",
        "leafType": "string",
        "line": 2
      }
    }
  ]
}
[exit 0]

candidate2

$ openclaw path find oc://session.jsonl/**/event --json
{
  "pattern": "oc://session.jsonl/**/event",
  "count": 1,
  "matches": [
    {
      "path": "oc://session.jsonl/L2/nest.deep/event",
      "match": {
        "kind": "leaf",
        "valueText": "y",
        "leafType": "string",
        "line": 2
      }
    }
  ]
}
[exit 0]
$ openclaw path find oc://session.jsonl/** --json
{
  "pattern": "oc://session.jsonl/**",
  "count": 7,
  "matches": [
    {
      "path": "oc://session.jsonl",
      "match": {
        "kind": "root",
        "ast": {
          "kind": "jsonl",
          "raw": "{\"id\":\"x\"}\n{\"nest\":{\"deep\":{\"event\":\"y\"}}}\n",
          "lines": [
            {
              "kind": "value",
              "line": 1,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "id",
                    "line": 1,
                    "value": {
                      "kind": "string",
                      "value": "x",
                      "line": 1
                    }
                  }
                ]
              },
              "raw": "{\"id\":\"x\"}"
            },
            {
              "kind": "value",
              "line": 2,
              "value": {
                "kind": "object",
                "line": 1,
                "entries": [
                  {
                    "key": "nest",
                    "line": 1,
                    "value": {
                      "kind": "object",
                      "line": 1,
                      "entries": [
                        {
                          "key": "deep",
                          "line": 1,
                          "value": {
                            "kind": "object",
                            "line": 1,
                            "entries": [
                              {
                                "key": "event",
                                "line": 1,
                                "value": {
                                  "kind": "string",
                                  "value": "y",
                                  "line": 1
                                }
                              }
                            ]
                          }
                        }
                      ]
                    }
                  }
                ]
              },
              "raw": "{\"nest\":{\"deep\":{\"event\":\"y\"}}}"
            }
          ],
          "lineEnding": "\n"
        },
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L1/id",
      "match": {
        "kind": "leaf",
        "valueText": "x",
        "leafType": "string",
        "line": 1
      }
    },
    {
      "path": "oc://session.jsonl/L2",
      "match": {
        "kind": "node",
        "descriptor": "jsonl-line",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest",
      "match": {
        "kind": "node",
        "descriptor": "jsonc-object",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest.deep",
      "match": {
        "kind": "node",
        "descriptor": "jsonc-object",
        "line": 2
      }
    },
    {
      "path": "oc://session.jsonl/L2/nest.deep.event",
      "match": {
        "kind": "leaf",
        "valueText": "y",
        "leafType": "string",
        "line": 2
      }
    }
  ]
}
[exit 0]

All candidate returned addresses are independently resolved through the real CLI (including every bare-** result). Every run also checks the non-recursive JSONL address, JSON **, YAML **, and a depth32 size-bounded JSONL case. The controls return the same y; main misses both nested JSONL cases, candidate finds and resolves both. Files remain byte-identical.

Regression fixture red on main:2 intended failures/88passes (newly valid physical-line traversal ordering and the single-globstar nested match). Candidate finder plus YAML suites:130passed/2files, including existing expansion-budget and deep-path checks. Targeted lint/format pass. Consolidated into existing test table and removed redundant round-trip coverage; tests+3/-3(net0), production+17/-1, docs+2. The helper returns the original run array when no repair is needed, avoiding no-op copies.

Host/container source SHA256 match: find.ts1872076017ad6a15a193f621d9311b7973a61049a3cefeb04b9ee3a04d009402; jsonl/line.ts ff251ab45a34798458acc3e1cbddd327b600d88bddafc581dcf5fe3f03a0f8d0. Contributor commits, including the latest test cleanup5597f11bf23c, are preserved.

@obviyus

obviyus commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@openclaw-barnacle openclaw-barnacle Bot added the docs Improvements or additions to documentation label Nov 1, 2026
@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Nov 1, 2026
@obviyus
obviyus merged commit 0f4e9ca into openclaw:main Nov 1, 2026
107 of 109 checks passed
@obviyus

obviyus commented Nov 1, 2026

Copy link
Copy Markdown
Collaborator

Landed in 0f4e9ca. Thanks @jerome-queck. Recursive ** paths now find nested JSONL records.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 1, 2026
…lot (openclaw#189960)

fix(cli): make recursive `**` paths find nested JSONL records

In JSONL files, the documented recursive `**` path segment didn't descend into each record. `**/event` found nothing (count 0, exit 1), and a bare `**` returned only the top-level entries. Recursive paths now walk into each JSONL record as they do for JSON and YAML. There is no new syntax, and the existing depth bound still applies.

Evidence: built Linux Node 24.22.1 CLI. On main, nested JSONL `**/event` returned 0 results and bare `**` returned 3 of 7 (twice); with this change it found the nested match and all 7 results (twice), and every returned address resolved through the real CLI. Non-recursive JSONL, JSON and YAML recursion, and a depth-32 bounded case behaved the same on both refs, and files were unchanged. Details: openclaw#189960 (comment).

Thanks @jerome-queck.

Co-authored-by: scout <scout@local>
Co-authored-by: Ayaan Zaidi <[email protected]>
maplel pushed a commit to maplel/openclaw that referenced this pull request Nov 24, 2026
…lot (openclaw#189960)

fix(cli): make recursive `**` paths find nested JSONL records

In JSONL files, the documented recursive `**` path segment didn't descend into each record. `**/event` found nothing (count 0, exit 1), and a bare `**` returned only the top-level entries. Recursive paths now walk into each JSONL record as they do for JSON and YAML. There is no new syntax, and the existing depth bound still applies.

Evidence: built Linux Node 24.22.1 CLI. On main, nested JSONL `**/event` returned 0 results and bare `**` returned 3 of 7 (twice); with this change it found the nested match and all 7 results (twice), and every returned address resolved through the real CLI. Non-recursive JSONL, JSON and YAML recursion, and a depth-32 bounded case behaved the same on both refs, and files were unchanged. Details: openclaw#189960 (comment).

Thanks @jerome-queck.

Co-authored-by: scout <scout@local>
Co-authored-by: Ayaan Zaidi <[email protected]>

Release adaptation: Retain existing physical Ldigits line selector, move recursive-consumed value keys into value slots; no new syntax or persistence behavior. Later Markdown union/frontmatter fixes independent.

(cherry picked from commit 0f4e9ca)

Co-authored-by: RomneyDa <[email protected]>
(cherry picked from commit 87eeb5077e7d4840bd16cc4619e762564065920c)
(cherry picked from commit e6c654bda4095d463168b4040614551c8396576b)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation extensions: oc-path P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: openclaw path find 'oc://x.jsonl/**/key' returns no matches for keys nested inside JSONL line values

2 participants