Skip to content

fix: restore bundled Mermaid parser license notices - #157461

Merged
steipete merged 4 commits into
mainfrom
fix/mermaid-parser-notices-followup-20260924
Sep 25, 2026
Merged

steipete merged 4 commits into
mainfrom
fix/mermaid-parser-notices-followup-20260924

Conversation

@steipete

@steipete steipete commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

The native license catalogs omit parser libraries embedded in the bundled Mermaid engine.

User Impact

Android and iOS packages include the missing upstream license notices. The shared Apple renderer resources retain the same notices.

Why This Change Was Made

Mermaid's classic bundle still embeds Chevrotain, Langium, and parser-support libraries after the renderer cleanup in #157161. This restores nine notice entries, preserves their upstream license texts, and extends the existing Android packaged-asset inventory assertion. Newer JNA, libffi, and libsodium notices remain intact.

The old CI also exposed an insufficient readiness check in the Swift compact-error test: its fake transport records invocation before the awaited operation settles. Three existing predicates now wait for the exact call list and the existing submission owner to retire before checking the unchanged error/retry result. This preserves the public /compact path, deadlines, assertions, and deliberately in-flight concurrency test.

Evidence

Current candidate 7428266b640a incorporates main b6577e17b2c0fc7a8cf26033fd7a2a94199e7684, including the owning Team Reports test-import repair 7c4866c7. All 21 PR paths retain the identical added/deleted patch lines after this mechanical refresh; the two completed independent reviews are reused, not claimed as newly rerun. The 19 notice-file postimages are identical to the original PR. All nine Android/iOS pairs match, and all twelve upstream package license bodies, including the Chevrotain subpackages, are preserved after line-ending normalization. The source inventories contain 95 Android and 85 iOS notices; these are source counts, not a fresh packaged-runtime result. Independent P0–P2 reviews of the refreshed notice change and the separate Swift test correction found no actionable findings. Diff checks pass.

Historical proof on cf1d310b: native renderer generation and Apple resource preparation passed; all four Android license tests passed and all 92 then-packaged Android notices matched their source texts. The focused Android command took 164.55 seconds including compilation; test bodies took 5.62 seconds. Those results retain their original attribution and are not presented as fresh tests of this candidate.

Earlier CI 36037968095 tested merge e6416865 (cf1d310b plus 0eecafaf). Its UI menu failure has the relevant fixture repair #157494 (2019fd9288c9) incorporated here. Its sole macOS package failure was the compact generic-error assertion among 1,785 tests. The source establishes that the old transport-call predicate can precede error publication; the log does not reveal the historical executor schedule or actual error value. No reconstruction of that schedule is claimed.

CI 36176488439 stopped in extension test types on tested merge 09a7b2d7 (98d31175 plus main ebdf8ab4): the Team Reports scheduler test still imported a barrel removed by #157819, causing TS2307 and lost contextual typing. The notice/Swift patch does not touch that code. The now-incorporated owning main fix 7c4866c7 uses the two existing source-owner imports; its code and ancestry were verified. Other cancelled jobs are not passes. Fresh CI 36181002743 passed on exact 7428266b640a158e890745374a2afd5c835d938f, testing merge 541755ac14d9f4eabb2fb13adf577f9e15571363. Android play/third-party/wear tests, native access, ktlint, both macOS Swift jobs, extension test types, and iOS screenshot evidence all passed. The current Android report verifies all four license tests (0 skips/failures/errors): 5.9 seconds for the class, including 5.08 seconds for the 95-name packaged-asset assertion; the whole third-party Gradle gate took 433 seconds. The artifact ZIP digest matches the CI upload record. Current CI also rebuilt Mermaid and ran the maintained Apple resource preparation. The parallel OpenClawKit run passed 1,796 tests in 33.271 seconds; the two modified error/retry cases passed in 4.688/4.865 seconds. These are CI case/suite times, not isolated file command timings. The prepared deterministic Swift ordering control has not run. The synchronization correction adds no tests, sleeps, retries, process boots, or longer deadlines; fresh CI timings are recorded above. No iOS device or simulator test was run.

The separate Shared OpenClawKit Periphery run 36181002368 fails on GatewayExternalAuthorizationError, its initializer, and errorDescription. Source/history review confirms those are dormant authorization scaffolding introduced by #157454, outside this PR's changed paths; the concrete production consumer remains in held #147244. This is a real unused-code finding, not an infrastructure failure or claimed scanner false positive. Removing only the three declarations would break the retained dependent scaffolding, while activating the held stack is outside this fix. No suppression, baseline change, or retry was used. The enforced openclaw/ci-gate and complete ordinary CI both pass on the current head.

Keep Chevrotain and parser-support attributions for implementation embedded in the pinned Mermaid classic bundle. Restore the original license texts in the Android and iOS catalogs and shared native notice, and update the packaged Android inventory regression. Preserve the existing ELK removal and renderer inputs.
@clawsweeper

clawsweeper Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@steipete
steipete marked this pull request as ready for review September 24, 2026 17:58
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 24, 2026
@clawsweeper

clawsweeper Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 25, 2026, 4:28 PM ET / 20:28 UTC (Revision 5).

ClawSweeper review

What this changes

Adds Mermaid parser dependency notices to Android, iOS, and shared Apple renderer resources, extends Android's packaged-license check, and makes Swift compact-command tests wait for completion.

Merge readiness

✅ Ready for maintainer review

Keep open: current main and v2026.9.6 still lack native notices for parser code in the pinned Mermaid bundle. The earlier merged renderer cleanup does not supply this correction, and the current patch has no demonstrated blocking defect.

Priority: P2
Reviewed head: 7428266b640a158e890745374a2afd5c835d938f

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The notice attribution is source-supported and exact-head package checks pass; direct iOS Licenses-screen observation was not supplied.
Proof confidence 🐚 platinum hermit (4/6) Not applicable: Repository State classifies the author as MEMBER, so the external-contributor proof gate does not apply. Exact-head CI checked Android packaged-license loading and Apple build preparation; the available screenshots depict the earlier renderer change rather than these license rows. No stored-data contract changes.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: Repository State classifies the author as MEMBER, so the external-contributor proof gate does not apply. Exact-head CI checked Android packaged-license loading and Apple build preparation; the available screenshots depict the earlier renderer change rather than these license rows. No stored-data contract changes.
Evidence reviewed 10 items Notice contract: The renderer guide requires notices for the exact classic bundle in both mobile catalogs and the shared Apple resource notice.
Pinned bundle: The renderer loads Mermaid's classic script; its package pins Mermaid 11.17.2.
Parser dependency attribution: The published @mermaid-js/parser 1.2.1 package identifies mermaid-js/mermaid as its repository. Its distributed parser chunks contain implementation labeled Chevrotain 11.1.2, Langium 4.2.1, the listed language-server packages, and vscode-uri 3.1.0. This resolves the earlier review's disputed vscode-uri attribution; the inspected artifact was https://registry.npmjs.org/@mermaid-js/parser/-/parser-1.2.1.tgz.
Findings None None.
Security None None.

How this fits together

OpenClaw packages a pinned Mermaid diagram bundle for native chat. Android and iOS read bundled license files for their Licenses screens, and the renderer build copies a shared notice into Apple resources.

flowchart LR
  A[Pinned Mermaid bundle] --> B[Dependency notice audit]
  B --> C[Android license files]
  B --> D[iOS license files]
  B --> E[Shared renderer notice]
  C --> F[Android Licenses screen]
  D --> G[iOS Licenses screen]
  E --> H[Apple renderer resources]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source +398, Tests +9, Other +691. Total +1098 across 21 files.

View PR surface stats
Area Files Added Removed Net
Source 1 398 0 +398
Tests 1 9 0 +9
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 19 697 6 +691
Total 21 1104 6 +1098

Review metrics

None.

Technical review

Best possible solution:

Keep one audited set of license texts for parser code present in the pinned classic bundle and distribute it through the existing Android and Apple notice paths.

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

Yes, from source: the pinned bundle contains the parser libraries while current main lacks their native notices. No device reproduction was performed.

Is this the best way to solve the issue?

Yes. The patch uses the existing native notice owners and makes the Swift test wait for the result it already asserts.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 169da0025a2f.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Missing third-party notices affect native packages, with a bounded correction and no demonstrated runtime outage.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: Repository State classifies the author as MEMBER, so the external-contributor proof gate does not apply. Exact-head CI checked Android packaged-license loading and Apple build preparation; the available screenshots depict the earlier renderer change rather than these license rows. No stored-data contract changes.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • joshavant: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (4 earlier review cycles)
  • reviewed 2026-09-24T18:05:39.184Z sha cf1d310 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-24T18:16:41.736Z sha cf1d310 :: needs changes before merge. :: [P2] Remove the unsupported vscode-uri attribution
  • reviewed 2026-09-25T19:04:35.083Z sha 98d3117 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-25T19:51:08.647Z sha 7428266 :: needs maintainer review before merge. :: none

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 24, 2026
@steipete steipete self-assigned this Sep 25, 2026
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Sep 25, 2026
@steipete
steipete merged commit e069864 into main Sep 25, 2026
191 of 192 checks passed
@steipete
steipete deleted the fix/mermaid-parser-notices-followup-20260924 branch September 25, 2026 21:21
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 26, 2026
* fix(native): restore bundled Mermaid parser notices

Keep Chevrotain and parser-support attributions for implementation embedded in the pinned Mermaid classic bundle. Restore the original license texts in the Android and iOS catalogs and shared native notice, and update the packaged Android inventory regression. Preserve the existing ELK removal and renderer inputs.

* chore: refresh Mermaid notices onto current main

* test(chat): wait for compact commands to settle

* chore: incorporate team reports test import fix

Co-authored-by: Peter Steinberger <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android app: ios App: ios P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL 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.

1 participant