Skip to content

feat(sessions): persist plugin state across runtimes - #332

Merged
w0wl0lxd merged 8 commits into
mainfrom
feat/session-state-persistence
Aug 4, 2026
Merged

feat(sessions): persist plugin state across runtimes#332
w0wl0lxd merged 8 commits into
mainfrom
feat/session-state-persistence

Conversation

@w0wl0lxd

@w0wl0lxd w0wl0lxd commented Aug 4, 2026

Copy link
Copy Markdown
Owner

Summary

  • capture and hydrate scoped Lua plugin state in UI sessions
  • migrate todo_write to root-scoped host state and preserve todos across turns
  • persist snapshots in headless, ACP, SDK, print, and agent session loops through a dependency-inverted lifecycle interface
  • checkpoint streamed transcript progress without blocking periodic UI saves on Lua lifecycle drains

Stack

Validation

  • cargo fmt --all -- --check
  • stylua --check plugins/todo_write/init.lua
  • focused UI/Lua persistence tests: 6 passed
  • headless lifecycle persistence tests: 2 passed
  • cargo clippy -p n00n-agent -p n00n-lua -p n00n-acp -p n00n --tests -- -D warnings
  • cargo check -p n00n-agent -p n00n-lua -p n00n-acp -p n00n

A combined 1,989-test nextest run was OOM-killed with exit 137 during startup after compilation, so validation was rerun in bounded package/test slices.

@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@w0wl0lxd, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 59 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: eb2952e1-4f88-49e4-a7df-98c0e5177626

📥 Commits

Reviewing files that changed from the base of the PR and between 1b3bc68 and 8081624.

📒 Files selected for processing (20)
  • changelog.d/332.added.md
  • n00n-acp/src/lib.rs
  • n00n-acp/src/server.rs
  • n00n-agent/src/headless.rs
  • n00n-lua/src/api/autocmd.rs
  • n00n-lua/src/api/util/ctx.rs
  • n00n-lua/src/loader.rs
  • n00n-lua/src/state.rs
  • n00n-lua/tests/plugin_host.rs
  • n00n-ui/src/app/mod.rs
  • n00n-ui/src/app/session.rs
  • n00n-ui/src/app/tests.rs
  • n00n-ui/src/event_loop.rs
  • plugins/todo_write/init.lua
  • site/docs/content/lua-api/_index.md
  • src/cmd/acp.rs
  • src/cmd/agent.rs
  • src/cmd/tui.rs
  • src/print.rs
  • src/sdk_mode.rs

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@w0wl0lxd
w0wl0lxd marked this pull request as ready for review August 4, 2026 02:44
@w0wl0lxd
w0wl0lxd changed the base branch from feat/plugin-session-state-runtime to main August 4, 2026 03:44
@w0wl0lxd

w0wl0lxd commented Aug 4, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@codex review

@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

@w0wl0lxd I will review pull request #332.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 008bdf3e6e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread n00n-agent/src/headless.rs Outdated
Comment thread plugins/todo_write/init.lua
@codecov

codecov Bot commented Aug 4, 2026

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Criterion

Details
Benchmark suite Current: 8081624 Previous: 1b3bc68 Ratio
fib/jit_mlua_hook 6496444 ns/iter (± 162861) 6628733 ns/iter (± 86431) 0.98
fib/jit_watchdog 2444554 ns/iter (± 10045) 2226717 ns/iter (± 19758) 1.10
fib/jit_none 2442780 ns/iter (± 90549) 2254120 ns/iter (± 85186) 1.08
fib/interp_mlua_hook 7611655 ns/iter (± 47701) 8206415 ns/iter (± 40916) 0.93
fib/interp_watchdog 3892075 ns/iter (± 44404) 4323241 ns/iter (± 85124) 0.90
fib/interp_none 3801043 ns/iter (± 19880) 4331679 ns/iter (± 31861) 0.88
buffer_rw/jit_mlua_hook 554899 ns/iter (± 10624) 579585 ns/iter (± 1912) 0.96
buffer_rw/jit_watchdog 167768 ns/iter (± 428) 192203 ns/iter (± 586) 0.87
buffer_rw/jit_none 167657 ns/iter (± 215) 191894 ns/iter (± 623) 0.87
buffer_rw/interp_mlua_hook 1066648 ns/iter (± 7253) 1047758 ns/iter (± 17667) 1.02
buffer_rw/interp_watchdog 615314 ns/iter (± 8905) 582678 ns/iter (± 1397) 1.06
buffer_rw/interp_none 615272 ns/iter (± 4227) 581913 ns/iter (± 1629) 1.06
splash_render_120x40 64386 ns/iter (± 5922) 61270 ns/iter (± 8574) 1.05
splash_render_200x60 174179 ns/iter (± 11103) 128212 ns/iter (± 27285) 1.36

This comment was automatically generated by workflow using github-action-benchmark.

@w0wl0lxd
w0wl0lxd enabled auto-merge (squash) August 4, 2026 04:43
@w0wl0lxd
w0wl0lxd merged commit 5e80fc7 into main Aug 4, 2026
30 checks passed
@linear-code

linear-code Bot commented Aug 4, 2026

Copy link
Copy Markdown

N00N-184

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.

1 participant