Skip to content

feat(resources): run btop itself, embedded and focused on coding agents - #28

Merged
senamakel merged 60 commits into
tinyhumansai:mainfrom
senamakel:btop-agents
Oct 29, 2026
Merged

senamakel merged 60 commits into
tinyhumansai:mainfrom
senamakel:btop-agents

Conversation

@senamakel

Copy link
Copy Markdown
Member

The Resources tab was a hand-written btop clone in Rust (~11.7k lines: sampler, plots, CPU/mem/net/disk panels, an agents table). This replaces all of it with btop itself, vendored as C++ source, compiled into the medulla binary, and run in-process. Its process box is narrowed to coding agents.

What changes

Vendored btop (vendor/btop, v1.4.8, Apache-2.0). This is plain source, not a submodule. It was imported unmodified first (1e647da7), so git diff 1e647da7 -- vendor/btop is exactly our patch set. vendor/btop/MEDULLA.md lists every change.

  • Embedding seam (btop_embed.{hpp,cpp}, include/medulla_btop.h). btop no longer owns a terminal:
    • output goes to a buffer the host drains;
    • the terminal size comes from the host;
    • input is a queue the host feeds;
    • interrupts are condvar notifies, not SIGUSR1;
    • q and menu Quit hand control back to the host instead of calling quick_exit;
    • fatal errors unwind btop's own thread;
    • config lives under $MEDULLA_HOME/local/btop/, so a standalone btop's config is never touched.
  • Cursor sequences. btop emitted HVP (CSI y;x f) and CSI s/u, which the vt100 crate doesn't implement. It now emits CUP and ESC 7/8.
  • Agent focus. A new proc_agents option (default on, toggled with A, also in Options):
    • the proc box becomes agents and shows only the agent processes Medulla names, plus their descendants (tree view on by default);
    • the User column becomes Agent: ◆ Claude for agents Medulla launched, plain Codex for external ones, ↳ Claude dimmed on child processes;
    • when no agents are running, the box says so and points at A.
  • Shutdown. An atexit hook stops btop and saves its config before C++ static destructors run.

medulla-btop crate (src/btop):

  • build.rs compiles btop with cc (C++23). On Linux it picks g++-14 when the default g++ is older, which is the case on Ubuntu 24.04.
  • Btop is a safe handle over the C ABI: start, resize, send, set_visible, set_agents, drain, take_leave, error, stop.
  • On Windows, which has no btop collector, nothing is compiled and start returns Unsupported.

TUI (src/tui/src/ui/btop/, ui/app/resources/):

  • One process-wide pane, because btop starts once per process: a vt100 emulator fed from btop, blitted cell by cell into the ratatui frame.
  • Keys and mouse are encoded as xterm bytes and SGR mouse reports. Tab, Shift-Tab, ⌃C, ⌃O and ⌃T stay Medulla's.
  • btop is paused whenever another tab is on screen. A waker redraws as soon as btop has output.
  • An agent feed thread, running only while the tab is visible, reads exe, argv and start time with sysinfo, runs the existing SDK classifier and launch registry (discover_registered_agents), and hands btop {pid, label, launched}.

Removed:

  • the Rust sampler, plots and panels, plus event_loop/resources.rs;
  • the Settings › Resources page, so later subpages move up one digit;
  • [resources] and [theme.resources] config. Old configs still load and those tables are ignored (pinned by a test).
  • The remote-serve per-session usage annotator. Its only reader was the old tab. The usage wire field stays and is now always empty, so mixed-version hosts keep working.

Build and release:

  • g++-14 added to the Linux native-deps step;
  • new btop (macOS) CI job (cargo test -p medulla-btop), so an Apple-clang gap shows up on the PR rather than at release time;
  • medulla-btop added to scripts/release/bump-version.sh, without which the next release's --locked build would fail;
  • DEVELOPING.md documents the C++23 compiler requirement.

Not carried over

  • Remote hosts' agents. btop shows this machine only, so the old tab's remote agent rows are gone.
  • Old tab-specific settings. Disk filters, presets and colours now live in btop's own menu (Esc / o).

Validation

  • cargo fmt --all -- --check: pass
  • cargo clippy --locked --all-targets -- -D warnings: pass
  • cargo test --locked --no-fail-fast: every TUI, btop and link target passes. The SDK lib (no logic changes here; only config types removed) had one different timing test fail per full-parallel run on a loaded box (a_dead_socket_is_reaped, an_abort_interrupts_the_turn…, the_sweep_spans…). Each passes alone, and the whole SDK lib passes with --test-threads=8 (2406/2406).
  • bash scripts/release/test-bump-version.sh: pass. It fails without the medulla-btop entry.
  • bash scripts/check-public-boundary.sh: pass
  • New tests:
    • the btop lifecycle (start, draw, agents box, q hands back, second start refused);
    • the App tab end to end against the real btop (layout, the A toggle, q back to Sessions, pause and resume);
    • key and mouse encoding, the cell blit, the agent-table mapping;
    • an old config with the retired tables still loads.
    • The layout assertion fails against the old HVP sequence (verified).
  • Manual run under tmux (--mock, 170×45 and resized to 120×36): btop renders natively, the agents box shows the live Claude and Codex trees, A and Esc work, q returns to Sessions, btop's threads sit idle while hidden, and ⌃C exits 0 with btop.conf saved.
  • Not verified locally: the macOS build. The new CI job covers it.

senamakel and others added 30 commits October 28, 2026 18:49
Vendor the btop system monitor and its bundled fmt headers under vendor/btop so the project can build against a pinned copy instead of relying on a system install.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a header that exposes the interface needed to embed btop's
collection and drawing routines into another application. This lets
callers drive btop without going through its standalone main loop.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a new header under the vendored btop include directory to expose the medulla integration interface.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Adds the btop embedding source file to the vendored btop tree so the embedded build path can be compiled.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The resize handler short-circuited on the width comparison, so the height
exchange was skipped whenever the width was unchanged. Both exchanges now run
before the early return so the stored dimensions stay in sync.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The vendored btop no longer installs signal handlers or calls quick_exit from clean_quit; fatal errors now throw Embed::Fatal so the host can report the message and unwind btop's thread instead of terminating the process. The standalone main entry point and its CLI, config and TTY setup were removed since Medulla drives btop through the embed API.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Adds btop_embed_main, an entry point that runs btop's main loop on a
host-created thread without argument parsing, controlling terminal or
signal handling. It reads config and themes from a host-chosen directory,
pauses drawing while the host hides the view, and unwinds cleanly when
the host requests a stop.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Replace direct terminal writes, stdin polling, and signal-based interrupts with Embed calls so btop can run as an embedded pane driven by a host process. Quit requests now go through Embed::request_leave instead of exiting directly, letting the host decide when to tear down the session.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The terminal resize loop now exits early when the embedded instance is stopping or hidden, preventing it from spinning while the UI is not visible. The ctrl_r reload shortcut sets the reload flag directly instead of raising SIGUSR2, so reloads no longer depend on signal handling.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Declare an atomic reload_conf flag alongside init_conf in the Global namespace so configuration reloads can be signalled across threads.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Delete the vendored btop command-line parser implementation and header, which are no longer referenced by the build.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Removed the btop_cli.hpp include from the vendored btop source since nothing in the file references it, keeping the vendored tree free of a stale dependency.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Register the new btop crate as a workspace member so it is built and tested alongside the existing crates.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Wire the vendored btop crate into the workspace and the TUI so the host Resources tab can drive it through its C ABI.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Add a build script that compiles the btop sources and wires up the native build so the integration can be built as part of the crate.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The build script's module docs referenced `Btop::start` via an intra-doc link, which cannot resolve from a build script and would warn during doc builds. The reference is now plain code text, and the trailing link definition was dropped.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a new Rust crate exposing FFI bindings so btop's types and core library can be consumed from Rust. This provides the foundation for integrating btop functionality into Rust-based tooling.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a new handle module that wraps btop process interaction, giving the rest of the code a single place to start, stop, and query btop instances instead of duplicating that logic.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Registers the new medulla-btop package and wires it into the medulla dependency set so the workspace lockfile reflects the added crate.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Add a proc_agents option that narrows the process box to coding-agent
processes and their children, toggled with the A key and exposed in the
options menu. Tree view and the filter are enabled by default so the
process list starts focused on agents.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The agents toggle now waits on the active runner before changing the proc_agents config, since the box title depends on the mode and the boxes need to be rebuilt safely.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce an agents mode that narrows the process box to processes belonging to coding agents reported by the host, marking each process with its agent label and whether it is the agent root or a descendant. Agent ownership is resolved by walking each process up its ancestry with memoisation, and the filter is recomputed whenever the agent set or the toggle changes so the visible tree stays current.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The macOS collector now re-runs filtering whenever the agent set or the agents toggle changes, and the filter pass also applies in agent mode even with an empty filter string. This keeps the process list consistent when switching agent mode instead of leaving stale filtered state.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The process box now shows an Agent column in agents mode, labelling each agent's own process and dimming its descendants, and displays a hint instead of a blank list when no agents are running. The box title and filter controls shift to accommodate the longer title.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The resource sampler, plot rendering, and their configuration types have been deleted along with the associated tests and the resources tab feature test. This removes the resource monitoring subsystem entirely.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The resources tab plan and its overview screenshot have been deleted now that the feature has shipped, and the corresponding module no longer needs the leftover code.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a new btop-inspired UI module with its own types and renderer to display system resource usage in the TUI.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce feed and input handling for the btop view so it can consume and respond to data.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Introduce a new pane module that renders btop-style panes in the TUI, giving the interface a richer, boxed layout for displaying system information.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
senamakel and others added 22 commits October 28, 2026 19:04
Drops the ResourcesConfig and ResourcesThemeConfig types along with the resources field on TuiConfig and the theme's resource color overrides, since the Resources tab they configured no longer exists.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The render loop now calls hide_resources_unless_shown before drawing each frame so the resources pane only collects and draws while its tab is on screen, matching btop's behaviour.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Removed the remaining references to the retired `theme.resources` table from the theme tests and updated the persistence test's doc comment to explain that the table is now an unknown section that must still survive a save.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Add a test module covering the btop UI rendering so its behaviour is verified and regressions are caught.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Add unit tests covering the app resources module to verify its behaviour and guard against regressions.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The resources pane is now hidden as soon as it reports that the user is leaving, so it no longer stays visible while the tab switches to Sessions.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The cursor positioning, save, and restore sequences were switched from HVP, CSI s, and CSI u to CUP, DECSC, and DECRC, and the clear sequence now homes the cursor with CUP, because the host's vt100 emulator does not implement the former forms.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Extend the btop tab test to check that the emulator applies btop's absolute cursor moves, verifying the cpu box title sits on the first row and the frame stays on the left edge. Without this, boxes would run together and the test would still pass.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Extract a helper that checks the cpu box frame and title on the first row, and wait for that frame rather than the bare word "cpu", which the agents box's sort label also contains. The left-edge check now skips the title row explicitly instead of relying on the consumed iterator.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Apps without a medulla home now resolve their btop config to a single fixed scratch directory instead of a per-process one, so tests and other home-less runs reuse the same location.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Adds a macOS CI job that builds and tests the vendored btop crate so Apple-clang issues surface on pull requests instead of at release time. The native-deps action now installs g++-14 because the vendored btop requires C++23 ranges support that Ubuntu 24.04's default g++ 13 lacks.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Cargo reads every workspace member's manifest, including path dependencies, even when building with `-p`, so the submodules must be checked out before the embedded btop test job runs.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The release script now updates the lockfile entry for medulla-btop alongside the other workspace members, so its version stays in sync when bumping the shared version.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The fixture lockfile now includes a medulla-btop package and the expected version count is raised to four, so the test exercises the newly added workspace crate.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Expands the repository layout notes to cover the vendored C++ btop source and the medulla-btop crate that compiles and embeds it, plus the TUI host side behind the Resources tab, so contributors know where the btop integration lives and that its patches are tracked in vendor/btop/MEDULLA.md.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Added a note to the development guide explaining that building requires a C++23 compiler because the Resources tab compiles btop from vendor/btop, and listed the minimum GCC, Clang, and Xcode versions along with the Windows exception.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Adds a test asserting that a config still containing the old `[resources]` and `[theme.resources]` tables parses successfully, since those tables are now ignored after the Resources tab moved to btop.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The TOML fixture in the retired-resources-tables test now uses double-hash raw string delimiters so the embedded quoted values no longer terminate the literal early.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Reformatted long expressions, import lists, and closures to satisfy rustfmt, with no behavioural changes.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The navigation test now expects "Feedback" instead of "Resources" after moving down from the nav, matching the current subpage ordering.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Adjust the number-key navigation test to expect the Feedback subpage on key 6 and Account on key 7, matching the current subpage ordering.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The event loop now hides the btop pane instead of shutting it down when a session ends, since a relogin re-enters the loop in the same process and btop can only start once per process. An atexit handler stops and saves btop before static destructors run, the runner thread is joined on stop, and the error query checks the length before allocating a buffer each frame.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
@coderabbitai

coderabbitai Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

  • Run on-demand review

This review includes 156 billable files and costs up to $39.00.

View limit details

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 58013eaa-7969-4028-a81c-2f56dbd58f44
Commits

Reviewing files that changed from the base of the PR and between def8a08 and 8965007.

Files ignored due to path filters: 2
  • Cargo.lock is excluded by !**/*.lock
  • docs/screenshots/resources-overview.svg is excluded by !**/*.svg
Files selected for processing: 156
  • .github/actions/native-deps/action.yml
  • .github/workflows/ci.yml
  • AGENTS.md
  • Cargo.toml
  • DEVELOPING.md
  • docs/plans/resources-tab.md
  • scripts/release/bump-version.sh
  • scripts/release/test-bump-version.sh
  • src/btop/Cargo.toml
  • src/btop/build.rs
  • src/btop/src/ffi.rs
  • src/btop/src/handle.rs
  • src/btop/src/lib.rs
  • src/btop/src/tests.rs
  • src/btop/src/types.rs
  • src/sdk/src/config/mod.rs
  • src/sdk/src/config/resources/mod.rs
  • src/sdk/src/config/resources/tests.rs
  • src/sdk/src/config/resources/types.rs
  • src/sdk/src/config/types/document.rs
  • src/sdk/src/config/types/mod.rs
  • src/sdk/src/config/types/presentation.rs
  • src/sdk/src/config/types_tests.rs
  • src/tui/Cargo.toml
  • src/tui/src/event_loop/mod.rs
  • src/tui/src/event_loop/resources.rs
  • src/tui/src/event_loop/types.rs
  • src/tui/src/remote/serve/entry.rs
  • src/tui/src/remote/serve/mod.rs
  • src/tui/src/remote/serve/tests/mod.rs
  • src/tui/src/remote/serve/tests/usage.rs
  • src/tui/src/remote/serve/usage.rs
  • src/tui/src/ui/app/input/mouse.rs
  • src/tui/src/ui/app/keys/mod.rs
  • src/tui/src/ui/app/keys/settings/mod.rs
  • src/tui/src/ui/app/render/mod.rs
  • src/tui/src/ui/app/render/resources/agents/command.rs
  • src/tui/src/ui/app/render/resources/agents/mod.rs
  • src/tui/src/ui/app/render/resources/agents/rows.rs
  • src/tui/src/ui/app/render/resources/agents/tests.rs
  • src/tui/src/ui/app/render/resources/agents/types.rs
  • src/tui/src/ui/app/render/resources/agents_detail.rs
  • src/tui/src/ui/app/render/resources/mod.rs
  • src/tui/src/ui/app/render/settings/mod.rs
  • src/tui/src/ui/app/render/tests.rs
  • src/tui/src/ui/app/resources/agent_input.rs
  • src/tui/src/ui/app/resources/chrome.rs
  • src/tui/src/ui/app/resources/cpu/mod.rs
  • src/tui/src/ui/app/resources/cpu/tests.rs
  • src/tui/src/ui/app/resources/disks.rs
  • src/tui/src/ui/app/resources/disks_tests.rs
  • src/tui/src/ui/app/resources/input.rs
  • src/tui/src/ui/app/resources/keys.rs
  • src/tui/src/ui/app/resources/layout.rs
  • src/tui/src/ui/app/resources/mem.rs
  • src/tui/src/ui/app/resources/mod.rs
  • src/tui/src/ui/app/resources/net.rs
  • src/tui/src/ui/app/resources/net_tests.rs
  • src/tui/src/ui/app/resources/tests.rs
  • src/tui/src/ui/app/resources/tests/agent_rows.rs
  • src/tui/src/ui/app/resources/tests/agents.rs
  • src/tui/src/ui/app/resources/tests/controls.rs
  • src/tui/src/ui/app/resources/tests/mod.rs
  • src/tui/src/ui/app/resources/tests/panels.rs
  • src/tui/src/ui/app/resources/types.rs
  • src/tui/src/ui/app/settings_edit/mod.rs
  • src/tui/src/ui/app/settings_edit/resources/mod.rs
  • src/tui/src/ui/app/settings_edit/resources/rows.rs
  • src/tui/src/ui/app/settings_edit/resources/tests.rs
  • src/tui/src/ui/app/settings_edit/resources/types.rs
  • src/tui/src/ui/app/settings_edit/resources/values.rs
  • src/tui/src/ui/app/state.rs
  • src/tui/src/ui/app/types/model.rs
  • src/tui/src/ui/btop/feed.rs
  • src/tui/src/ui/btop/input.rs
  • src/tui/src/ui/btop/mod.rs
  • src/tui/src/ui/btop/pane.rs
  • src/tui/src/ui/btop/render.rs
  • src/tui/src/ui/btop/tests.rs
  • src/tui/src/ui/btop/types.rs
  • src/tui/src/ui/harness_pane/tests/shells.rs
  • src/tui/src/ui/mod.rs
  • src/tui/src/ui/plot/graph.rs
  • src/tui/src/ui/plot/meter.rs
  • src/tui/src/ui/plot/mod.rs
  • src/tui/src/ui/plot/symbols.rs
  • src/tui/src/ui/plot/tests.rs
  • src/tui/src/ui/resources/cpu.rs
  • src/tui/src/ui/resources/cpu_tests.rs
  • src/tui/src/ui/resources/mod.rs
  • src/tui/src/ui/resources/net.rs
  • src/tui/src/ui/resources/net_tests.rs
  • src/tui/src/ui/resources/sampler/disks.rs
  • src/tui/src/ui/resources/sampler/filters.rs
  • src/tui/src/ui/resources/sampler/history.rs
  • src/tui/src/ui/resources/sampler/linux.rs
  • src/tui/src/ui/resources/sampler/linux_tests.rs
  • src/tui/src/ui/resources/sampler/macos.rs
  • src/tui/src/ui/resources/sampler/mod.rs
  • src/tui/src/ui/resources/sampler/source.rs
  • src/tui/src/ui/resources/sampler/tests/filters.rs
  • src/tui/src/ui/resources/sampler/tests/mod.rs
  • src/tui/src/ui/resources/sampler/types.rs
  • src/tui/src/ui/theme/gradient.rs
  • src/tui/src/ui/theme/mod.rs
  • src/tui/src/ui/theme/tests.rs
  • src/tui/src/ui/theme/types.rs
  • src/tui/tests/feature_config_editor.rs
  • src/tui/tests/feature_resources_tab.rs
  • src/tui/tests/feature_settings.rs
  • vendor/btop/LICENSE
  • vendor/btop/MEDULLA.md
  • vendor/btop/README.md
  • vendor/btop/include/fmt/LICENSE.rst
  • vendor/btop/include/fmt/args.h
  • vendor/btop/include/fmt/base.h
  • vendor/btop/include/fmt/chrono.h
  • vendor/btop/include/fmt/color.h
  • vendor/btop/include/fmt/compile.h
  • vendor/btop/include/fmt/core.h
  • vendor/btop/include/fmt/format-inl.h
  • vendor/btop/include/fmt/format.h
  • vendor/btop/include/fmt/os.h
  • vendor/btop/include/fmt/ostream.h
  • vendor/btop/include/fmt/printf.h
  • vendor/btop/include/fmt/ranges.h
  • vendor/btop/include/fmt/std.h
  • vendor/btop/include/fmt/xchar.h
  • vendor/btop/include/medulla_btop.h
  • vendor/btop/include/widechar_width.hpp
  • vendor/btop/src/btop.cpp
  • vendor/btop/src/btop.hpp
  • vendor/btop/src/btop_config.cpp
  • vendor/btop/src/btop_config.hpp
  • vendor/btop/src/btop_draw.cpp
  • vendor/btop/src/btop_draw.hpp
  • vendor/btop/src/btop_embed.cpp
  • vendor/btop/src/btop_embed.hpp
  • vendor/btop/src/btop_input.cpp
  • vendor/btop/src/btop_input.hpp
  • vendor/btop/src/btop_log.cpp
  • vendor/btop/src/btop_log.hpp
  • vendor/btop/src/btop_menu.cpp
  • vendor/btop/src/btop_menu.hpp
  • vendor/btop/src/btop_shared.cpp
  • vendor/btop/src/btop_shared.hpp
  • vendor/btop/src/btop_theme.cpp
  • vendor/btop/src/btop_theme.hpp
  • vendor/btop/src/btop_tools.cpp
  • vendor/btop/src/btop_tools.hpp
  • vendor/btop/src/linux/btop_collect.cpp
  • vendor/btop/src/osx/btop_collect.cpp
  • vendor/btop/src/osx/sensors.cpp
  • vendor/btop/src/osx/sensors.hpp
  • vendor/btop/src/osx/smc.cpp
  • vendor/btop/src/osx/smc.hpp
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@tinysweeper

tinysweeper Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Tiny Sweeper review

Verdict: Incomplete · Priority: none
Coverage: Reviewed 10 of 158 files; not reviewed: Cargo.lock, docs/plans/resou…, and 113 additional unreviewed files; not reviewed (large PR): .github/actions/…, AGENTS.md, and 31 additional unreviewed files.
Pull request purpose (title): feat(resources): run…

Diagnostics and supporting details

Full summary

Pull request purpose (title): feat(resources): run btop itself, embedded and focused on coding agents. Tiny Sweeper completed its review of feat(resources): run btop itself, embedded and focused on coding agents. The latest-push-delta evidence is unavailable.

Unreviewed paths

  • .github/actions/native-deps/action.yml
  • AGENTS.md
  • Cargo.lock
  • DEVELOPING.md
  • docs/plans/resources-tab.md
  • docs/screenshots/resources-overview.svg
  • scripts/release/bump-version.sh
  • scripts/release/test-bump-version.sh
  • src/btop/src/ffi.rs
  • src/btop/src/lib.rs
  • src/btop/src/tests.rs
  • src/btop/src/types.rs
  • src/sdk/src/config/mod.rs
  • src/sdk/src/config/resources/mod.rs
  • src/sdk/src/config/resources/tests.rs
  • src/sdk/src/config/resources/types.rs
  • src/sdk/src/config/types/document.rs
  • src/sdk/src/config/types/mod.rs
  • src/sdk/src/config/types/presentation.rs
  • src/sdk/src/config/types_tests.rs
  • src/tui/src/event_loop/mod.rs
  • src/tui/src/event_loop/resources.rs
  • src/tui/src/event_loop/types.rs
  • src/tui/src/remote/serve/entry.rs
  • src/tui/src/remote/serve/mod.rs
  • src/tui/src/remote/serve/tests/mod.rs
  • src/tui/src/remote/serve/tests/usage.rs
  • src/tui/src/remote/serve/usage.rs
  • src/tui/src/ui/app/input/mouse.rs
  • src/tui/src/ui/app/keys/mod.rs
  • src/tui/src/ui/app/keys/settings/mod.rs
  • src/tui/src/ui/app/render/mod.rs
  • src/tui/src/ui/app/render/resources/agents/command.rs
  • src/tui/src/ui/app/render/resources/agents/mod.rs
  • src/tui/src/ui/app/render/resources/agents/rows.rs
  • src/tui/src/ui/app/render/resources/agents/tests.rs
  • src/tui/src/ui/app/render/resources/agents/types.rs
  • src/tui/src/ui/app/render/resources/agents_detail.rs
  • src/tui/src/ui/app/render/resources/mod.rs
  • src/tui/src/ui/app/render/settings/mod.rs
  • src/tui/src/ui/app/render/tests.rs
  • src/tui/src/ui/app/resources/agent_input.rs
  • src/tui/src/ui/app/resources/chrome.rs
  • src/tui/src/ui/app/resources/cpu/mod.rs
  • src/tui/src/ui/app/resources/cpu/tests.rs
  • src/tui/src/ui/app/resources/disks.rs
  • src/tui/src/ui/app/resources/disks_tests.rs
  • src/tui/src/ui/app/resources/input.rs
  • src/tui/src/ui/app/resources/keys.rs
  • src/tui/src/ui/app/resources/layout.rs
  • src/tui/src/ui/app/resources/mem.rs
  • src/tui/src/ui/app/resources/mod.rs
  • src/tui/src/ui/app/resources/net.rs
  • src/tui/src/ui/app/resources/net_tests.rs
  • src/tui/src/ui/app/resources/tests.rs
  • src/tui/src/ui/app/resources/tests/agent_rows.rs
  • src/tui/src/ui/app/resources/tests/agents.rs
  • src/tui/src/ui/app/resources/tests/controls.rs
  • src/tui/src/ui/app/resources/tests/mod.rs
  • src/tui/src/ui/app/resources/tests/panels.rs
  • src/tui/src/ui/app/resources/types.rs
  • src/tui/src/ui/app/settings_edit/mod.rs
  • src/tui/src/ui/app/settings_edit/resources/mod.rs
  • src/tui/src/ui/app/settings_edit/resources/rows.rs
  • src/tui/src/ui/app/settings_edit/resources/tests.rs
  • src/tui/src/ui/app/settings_edit/resources/types.rs
  • src/tui/src/ui/app/settings_edit/resources/values.rs
  • src/tui/src/ui/app/state.rs
  • src/tui/src/ui/app/types/model.rs
  • src/tui/src/ui/btop/mod.rs
  • src/tui/src/ui/btop/tests.rs
  • src/tui/src/ui/btop/types.rs
  • src/tui/src/ui/harness_pane/tests/shells.rs
  • src/tui/src/ui/mod.rs
  • src/tui/src/ui/plot/graph.rs
  • src/tui/src/ui/plot/meter.rs
  • src/tui/src/ui/plot/mod.rs
  • src/tui/src/ui/plot/symbols.rs
  • src/tui/src/ui/plot/tests.rs
  • src/tui/src/ui/resources/cpu.rs
  • src/tui/src/ui/resources/cpu_tests.rs
  • src/tui/src/ui/resources/mod.rs
  • src/tui/src/ui/resources/net.rs
  • src/tui/src/ui/resources/net_tests.rs
  • src/tui/src/ui/resources/sampler/disks.rs
  • src/tui/src/ui/resources/sampler/filters.rs
  • src/tui/src/ui/resources/sampler/history.rs
  • src/tui/src/ui/resources/sampler/linux.rs
  • src/tui/src/ui/resources/sampler/linux_tests.rs
  • src/tui/src/ui/resources/sampler/macos.rs
  • src/tui/src/ui/resources/sampler/mod.rs
  • src/tui/src/ui/resources/sampler/source.rs
  • src/tui/src/ui/resources/sampler/tests/filters.rs
  • src/tui/src/ui/resources/sampler/tests/mod.rs
  • src/tui/src/ui/resources/sampler/types.rs
  • src/tui/src/ui/theme/gradient.rs
  • src/tui/src/ui/theme/mod.rs
  • src/tui/src/ui/theme/tests.rs
  • src/tui/src/ui/theme/types.rs
  • src/tui/tests/feature_config_editor.rs
  • src/tui/tests/feature_resources_tab.rs
  • src/tui/tests/feature_settings.rs
  • vendor/btop/LICENSE
  • vendor/btop/MEDULLA.md
  • vendor/btop/README.md
  • vendor/btop/include/fmt/LICENSE.rst
  • vendor/btop/include/fmt/args.h
  • vendor/btop/include/fmt/base.h
  • vendor/btop/include/fmt/chrono.h
  • vendor/btop/include/fmt/color.h
  • vendor/btop/include/fmt/compile.h
  • vendor/btop/include/fmt/core.h
  • vendor/btop/include/fmt/format-inl.h
  • vendor/btop/include/fmt/format.h
  • vendor/btop/include/fmt/os.h
  • vendor/btop/include/fmt/ostream.h
  • vendor/btop/include/fmt/printf.h
  • vendor/btop/include/fmt/ranges.h
  • vendor/btop/include/fmt/std.h
  • vendor/btop/include/fmt/xchar.h
  • vendor/btop/include/medulla_btop.h
  • vendor/btop/include/widechar_width.hpp
  • vendor/btop/src/btop.cpp
  • vendor/btop/src/btop.hpp
  • vendor/btop/src/btop_config.cpp
  • vendor/btop/src/btop_config.hpp
  • vendor/btop/src/btop_draw.cpp
  • vendor/btop/src/btop_draw.hpp
  • vendor/btop/src/btop_embed.cpp
  • vendor/btop/src/btop_embed.hpp
  • vendor/btop/src/btop_input.cpp
  • vendor/btop/src/btop_input.hpp
  • vendor/btop/src/btop_log.cpp
  • vendor/btop/src/btop_log.hpp
  • vendor/btop/src/btop_menu.cpp
  • vendor/btop/src/btop_menu.hpp
  • vendor/btop/src/btop_shared.cpp
  • vendor/btop/src/btop_shared.hpp
  • vendor/btop/src/btop_theme.cpp
  • vendor/btop/src/btop_theme.hpp
  • vendor/btop/src/btop_tools.cpp
  • vendor/btop/src/btop_tools.hpp
  • vendor/btop/src/linux/btop_collect.cpp
  • vendor/btop/src/osx/btop_collect.cpp
  • vendor/btop/src/osx/sensors.cpp
  • vendor/btop/src/osx/sensors.hpp
  • vendor/btop/src/osx/smc.cpp
  • vendor/btop/src/osx/smc.hpp

Partial review reasons

  • critique: .github/actions/native-deps/action.yml — not selected by the large-review budget
  • security: .github/actions/native-deps/action.yml — not selected by the large-review budget
  • critique: AGENTS.md — not selected by the large-review budget
  • security: AGENTS.md — not selected by the large-review budget
  • critique: DEVELOPING.md — not selected by the large-review budget
  • critique: scripts/release/bump-version.sh — not selected by the large-review budget
  • security: scripts/release/bump-version.sh — not selected by the large-review budget
  • critique: scripts/release/test-bump-version.sh — not selected by the large-review budget
  • security: scripts/release/test-bump-version.sh — not selected by the large-review budget
  • critique: src/btop/src/ffi.rs — not selected by the large-review budget
  • security: src/btop/src/ffi.rs — not selected by the large-review budget
  • critique: src/btop/src/lib.rs — not selected by the large-review budget
  • security: src/btop/src/lib.rs — not selected by the large-review budget
  • critique: src/btop/src/tests.rs — not selected by the large-review budget
  • security: src/btop/src/tests.rs — not selected by the large-review budget
  • critique: src/btop/src/types.rs — not selected by the large-review budget
  • security: src/btop/src/types.rs — not selected by the large-review budget
  • critique: src/sdk/src/config/mod.rs — not selected by the large-review budget
  • security: src/sdk/src/config/mod.rs — not selected by the large-review budget
  • critique: src/sdk/src/config/types_tests.rs — not selected by the large-review budget
  • security: src/sdk/src/config/types_tests.rs — not selected by the large-review budget
  • critique: src/tui/src/event_loop/mod.rs — not selected by the large-review budget
  • security: src/tui/src/event_loop/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/event_loop/types.rs — not selected by the large-review budget
  • security: src/tui/src/event_loop/types.rs — not selected by the large-review budget
  • critique: src/tui/src/remote/serve/entry.rs — not selected by the large-review budget
  • security: src/tui/src/remote/serve/entry.rs — not selected by the large-review budget
  • critique: src/tui/src/remote/serve/mod.rs — not selected by the large-review budget
  • security: src/tui/src/remote/serve/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/input/mouse.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/input/mouse.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/keys/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/keys/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/keys/settings/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/keys/settings/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/render/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/render/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/render/settings/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/render/settings/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/resources/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/resources/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/resources/tests.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/resources/tests.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/state.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/state.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/app/types/model.rs — not selected by the large-review budget
  • security: src/tui/src/ui/app/types/model.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/btop/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/btop/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/btop/tests.rs — not selected by the large-review budget
  • security: src/tui/src/ui/btop/tests.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/btop/types.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/harness_pane/tests/shells.rs — not selected by the large-review budget
  • security: src/tui/src/ui/harness_pane/tests/shells.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/theme/mod.rs — not selected by the large-review budget
  • security: src/tui/src/ui/theme/mod.rs — not selected by the large-review budget
  • critique: src/tui/src/ui/theme/tests.rs — not selected by the large-review budget
  • security: src/tui/src/ui/theme/tests.rs — not selected by the large-review budget
  • critique: src/tui/tests/feature_config_editor.rs — not selected by the large-review budget
  • security: src/tui/tests/feature_config_editor.rs — not selected by the large-review budget
  • critique: src/tui/tests/feature_settings.rs — not selected by the large-review budget
  • security: src/tui/tests/feature_settings.rs — not selected by the large-review budget

Review snapshot

Change surface Files Review signal Count
Production 72 Active findings 0
Tests 30 Noted findings 0
Documentation 4 Resolved findings 0
Configuration 5 Pending checks/questions 97

Completeness: Incomplete
Test assessment: Test coverage is assessed from changed tests and lane evidence; execution is not claimed without trusted check data.

What changed

Resources is now btop embedded in-process. `src/btop/` (`medulla-btop`) compiles `vendor/btop` via `build.rs` with C++23, preferring `g++-14` on Linux when the default is older, and exposes `Btop` (`start`, `resize`, `send`, `set_visible`, `set_agents`, `drain`, `take_leave`, `error`, `stop`) over `vendor/btop/include/medulla_btop.h`; on unsupported targets nothing is compiled and `start` returns `StartError::Unsupported`. `src/tui/src/ui/btop/` hosts one process-wide pane: a `vt100` emulator, a cell-for-cell blit, key/mouse byte encoding, and an agent feed thread that classifies processes with the SDK classifier joined to the launch registry and hands btop `{pid, label, launched}`. `src/tui/src/ui/app/resources/mod.rs` draws that pane in the Resources tab, routes keys and mouse to it except Tab/Shift-Tab and the global chords (⌃C/⌃O/⌃T), returns to Sessions on btop's quit, and pauses btop off-screen; the event loop's waker sends `AppMsg::Redraw` instead of resource snapshots. The Rust sampler, plot widgets, panels, Agents table, Settings › Resources page, `[resources]`/`[theme.resources]` config, plan doc and screenshot, and remote-serve usage annotator are deleted; release tooling, CI and docs are updated for the new crate and compiler requirement.

Features

  • Added — medulla-btop crate compiling vendored btop behind a safe handle: Adds a workspace member whose build script compiles the vendored C++23 btop into a static library and exposes a thread-safe `Btop` handle; on targets without a btop collector the crate builds without linking and `Btop::start` reports `Unsupported`. (src/btop/build.rs, src/btop/src/handle.rs, src/btop/src/types.rs, src/btop/Cargo.toml, Cargo.toml)
  • Added — In-process btop pane with vt100 emulator, blit, input encoding and agent feed: The Resources tab renders btop natively: btop's ANSI output is drained into a vt100 emulator and blitted into the ratatui frame, crossterm keys and mouse events are re-encoded as xterm bytes and SGR reports, and a background feed tags classified agent processes so btop's agents box shows them. (src/tui/src/ui/btop/mod.rs, src/tui/src/ui/btop/pane.rs, src/tui/src/ui/btop/render.rs, src/tui/src/ui/btop/input.rs, src/tui/src/ui/btop/feed.rs, src/tui/src/ui/btop/types.rs)
  • Modified — Resources tab now drives the shared btop pane: `draw_resources` shows, pumps and blits the shared pane, `resources_key` forwards keys except Tab/Shift-Tab and the global chords, `resources_mouse` forwards pointer events inside the pane, and btop is paused whenever another tab is drawn. (src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/app/input/mouse.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/keys/mod.rs, src/tui/src/ui/app/state.rs, src/tui/src/ui/app/types/model.rs)
  • Modified — Event loop wakes on btop output instead of sampler snapshots: The background resource sampler is gone; the loop installs a waker that sends `AppMsg::Redraw`, hides btop on exit (pause, not stop) so a relogin re-enters the same process, and no longer retunes a sampler. (src/tui/src/event_loop/mod.rs, src/tui/src/event_loop/types.rs)
  • Removed — Retired Rust sampler, plot widgets, panels and Agents table: The hand-written Resources implementation is deleted: sampler and history, Linux/macOS collectors, disk/network/CPU/memory/net panels, chrome, layout, keys, agent input and rows, agent detail, plot graph/meter/symbols, theme gradients, and their unit tests. (src/tui/src/ui/resources/sampler/mod.rs, src/tui/src/ui/resources/sampler/source.rs, src/tui/src/ui/plot/mod.rs, src/tui/src/ui/app/resources/cpu/mod.rs, src/tui/src/ui/app/resources/net.rs, src/tui/src/ui/app/render/resources/agents/mod.rs, src/tui/src/ui/theme/gradient.rs, src/tui/src/ui/mod.rs)
  • Removed — Retired Resources configuration and Settings › Resources page: `[resources]` and `[theme.resources]` config types and their exports are removed, the Settings subpage and its editor are deleted (later subpages move up one digit), and a test pins that a config still carrying the retired tables loads with them ignored. (src/sdk/src/config/resources/types.rs, src/sdk/src/config/mod.rs, src/sdk/src/config/types/presentation.rs, src/sdk/src/config/types/document.rs, src/sdk/src/config/types_tests.rs, src/tui/src/ui/app/settings_edit/resources/mod.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/tui/src/ui/app/render/settings/mod.rs)
  • Removed — Remote-serve per-session usage annotator: The usage sampler and its tests are removed and `RemoteServer` no longer annotates session rows; `current_rows` now just builds wire rows, leaving the additive `usage` field unpopulated rather than dropping it. (src/tui/src/remote/serve/usage.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/remote/serve/entry.rs, src/tui/src/remote/serve/tests/mod.rs, src/tui/src/remote/serve/tests/usage.rs)
  • Modified — Build, CI and release wiring for the C++23 dependency: Linux native deps gain `g++-14`, a new `btop (macOS)` CI job runs `cargo test -p medulla-btop`, `medulla-btop` is added to the release bump-version package list and its lockfile fixture, and `DEVELOPING.md`/`AGENTS.md` document the compiler requirement and new crate. (.github/actions/native-deps/action.yml, .github/workflows/ci.yml, scripts/release/bump-version.sh, scripts/release/test-bump-version.sh, DEVELOPING.md, AGENTS.md)

Tests

  • unit — Pins key encoding (characters, control/alt, arrows, function keys, unsupported keys), SGR mouse encoding relative to the pane with out-of-area and unused events rejected, the cell-for-cell blit including wide glyphs, inverse and clipping, and the classified-agent-to-`AgentTag` mapping.: Covers the pure host-side translation layers where a regression would silently misroute input or corrupt the rendered grid. (src/tui/src/ui/btop/tests.rs)
  • integration — Asserts Tab and Shift-Tab still switch tabs and ⌃C still quits while the Resources tab is focused.: Confirms the documented global-chord carve-outs for Tab, Shift-Tab and ⌃C; the tests lane notes ⌃O and ⌃T are exempted in code but not covered. (src/tui/src/ui/app/resources/tests.rs, src/tui/src/ui/app/resources/mod.rs)
  • unit — Pins that a config still carrying the retired `[theme.resources]` and `[resources]` tables parses and keeps unrelated theme values.: Directly guards the backward-compatibility claim for old configs after the config types were removed. (src/sdk/src/config/types_tests.rs)
  • unit — Release script test fixture gains a `medulla-btop` lockfile entry and expects four rewritten workspace package versions.: Keeps the release bump-version script honest about the new workspace member; the description states it fails without the entry. (scripts/release/test-bump-version.sh, scripts/release/bump-version.sh)

Findings

No active actionable findings.

Before merge

  • Complete the critique review for src/tui/src/ui/btop/types.rs, src/tui/src/ui/btop/mod.rs, src/btop/src/ffi.rs, src/btop/src/lib.rs, src/tui/src/ui/theme/mod.rs, src/btop/src/types.rs, src/tui/src/ui/app/types/model.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/ui/app/state.rs, src/sdk/src/config/mod.rs, src/tui/src/ui/mod.rs, src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/btop/tests.rs, src/tui/src/ui/app/resources/tests.rs, src/btop/src/tests.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/sdk/src/config/types_tests.rs, src/tui/src/event_loop/mod.rs, src/tui/src/ui/app/keys/mod.rs, .github/actions/native-deps/action.yml, src/tui/src/ui/app/input/mouse.rs, DEVELOPING.md, scripts/release/test-bump-version.sh, src/tui/src/remote/serve/entry.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/render/settings/mod.rs, src/tui/src/event_loop/types.rs, src/tui/src/ui/harness_pane/tests/shells.rs, src/tui/src/ui/theme/tests.rs, src/tui/tests/feature_settings.rs, AGENTS.md, scripts/release/bump-version.sh, src/tui/tests/feature_config_editor.rs.
  • Complete the security review for src/tui/src/ui/btop/mod.rs, src/btop/src/ffi.rs, src/btop/src/lib.rs, src/tui/src/ui/theme/mod.rs, src/btop/src/types.rs, src/tui/src/ui/app/types/model.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/ui/app/state.rs, src/sdk/src/config/mod.rs, src/tui/src/ui/mod.rs, src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/btop/tests.rs, src/tui/src/ui/app/resources/tests.rs, src/btop/src/tests.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/sdk/src/config/types_tests.rs, src/tui/src/event_loop/mod.rs, src/tui/src/ui/app/keys/mod.rs, .github/actions/native-deps/action.yml, src/tui/src/ui/app/input/mouse.rs, scripts/release/test-bump-version.sh, src/tui/src/remote/serve/entry.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/render/settings/mod.rs, src/tui/src/event_loop/types.rs, src/tui/src/ui/harness_pane/tests/shells.rs, src/tui/src/ui/theme/tests.rs, src/tui/tests/feature_settings.rs, AGENTS.md, scripts/release/bump-version.sh, src/tui/tests/feature_config_editor.rs.
  • Review uncovered paths: .github/actions/native-deps/action.yml, AGENTS.md, DEVELOPING.md, scripts/release/bump-version.sh, scripts/release/test-bump-version.sh, src/btop/src/ffi.rs, src/btop/src/lib.rs, src/btop/src/tests.rs, src/btop/src/types.rs, src/sdk/src/config/mod.rs, src/sdk/src/config/types_tests.rs, src/tui/src/event_loop/mod.rs, src/tui/src/event_loop/types.rs, src/tui/src/remote/serve/entry.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/ui/app/input/mouse.rs, src/tui/src/ui/app/keys/mod.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/render/settings/mod.rs, src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/app/resources/tests.rs, src/tui/src/ui/app/state.rs, src/tui/src/ui/app/types/model.rs, src/tui/src/ui/btop/mod.rs, src/tui/src/ui/btop/tests.rs, src/tui/src/ui/btop/types.rs, src/tui/src/ui/harness_pane/tests/shells.rs, src/tui/src/ui/mod.rs, src/tui/src/ui/theme/mod.rs, src/tui/src/ui/theme/tests.rs, src/tui/tests/feature_config_editor.rs, src/tui/tests/feature_settings.rs.
Agent review details

critique

  • Conclusion: Neutral
  • Scope reviewed: incomplete; unanswered files: src/tui/src/ui/btop/types.rs, src/tui/src/ui/btop/mod.rs, src/btop/src/ffi.rs, src/btop/src/lib.rs, src/tui/src/ui/theme/mod.rs, src/btop/src/types.rs, src/tui/src/ui/app/types/model.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/ui/app/state.rs, src/sdk/src/config/mod.rs, src/tui/src/ui/mod.rs, src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/btop/tests.rs, src/tui/src/ui/app/resources/tests.rs, src/btop/src/tests.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/sdk/src/config/types_tests.rs, src/tui/src/event_loop/mod.rs, src/tui/src/ui/app/keys/mod.rs, .github/actions/native-deps/action.yml, src/tui/src/ui/app/input/mouse.rs, DEVELOPING.md, scripts/release/test-bump-version.sh, src/tui/src/remote/serve/entry.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/render/settings/mod.rs, src/tui/src/event_loop/types.rs, src/tui/src/ui/harness_pane/tests/shells.rs, src/tui/src/ui/theme/tests.rs, src/tui/tests/feature_settings.rs, AGENTS.md, scripts/release/bump-version.sh, src/tui/tests/feature_config_editor.rs
  • Lane summary: Reviewed 5 of 38 files — 33 not reviewed. Reviewed 5 files; 3 findings. 33 files were omitted: not selected by the large-review budget.

security

  • Conclusion: Neutral
  • Scope reviewed: incomplete; unanswered files: src/tui/src/ui/btop/mod.rs, src/btop/src/ffi.rs, src/btop/src/lib.rs, src/tui/src/ui/theme/mod.rs, src/btop/src/types.rs, src/tui/src/ui/app/types/model.rs, src/tui/src/remote/serve/mod.rs, src/tui/src/ui/app/state.rs, src/sdk/src/config/mod.rs, src/tui/src/ui/mod.rs, src/tui/src/ui/app/resources/mod.rs, src/tui/src/ui/btop/tests.rs, src/tui/src/ui/app/resources/tests.rs, src/btop/src/tests.rs, src/tui/src/ui/app/keys/settings/mod.rs, src/sdk/src/config/types_tests.rs, src/tui/src/event_loop/mod.rs, src/tui/src/ui/app/keys/mod.rs, .github/actions/native-deps/action.yml, src/tui/src/ui/app/input/mouse.rs, scripts/release/test-bump-version.sh, src/tui/src/remote/serve/entry.rs, src/tui/src/ui/app/render/mod.rs, src/tui/src/ui/app/render/settings/mod.rs, src/tui/src/event_loop/types.rs, src/tui/src/ui/harness_pane/tests/shells.rs, src/tui/src/ui/theme/tests.rs, src/tui/tests/feature_settings.rs, AGENTS.md, scripts/release/bump-version.sh, src/tui/tests/feature_config_editor.rs
  • Lane summary: Reviewed 7 of 38 files — 31 not reviewed. Reviewed 7 files; 0 findings. 31 files were omitted: not selected by the large-review budget. 1 file was not security-reviewed: DEVELOPING.md (prose or tabular data).

tests

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: The tests lane answered: the btop lifecycle test walks start/draw/set_agents/resize/take_leave/second-start/stop against the real compiled btop, the input and blit helpers have precise byte- and cell-level assertions, the agent table test pins launched/pid semantics including the in-process fallback, and the Resources-tab test asserts box framing, the `A` toggle, `q` returning to Sessions, and btop being paused off screen.
  • Positive: The tests lane also noted it could not verify the vendor/btop C ABI (submodule not in the index), so the FFI-safety and `raw_agents` comments are unproven there, while nothing in the diff shows them false.
  • Lane summary: The tests in this revision are substantive: the btop lifecycle test walks start/draw/set_agents/resize/take_leave/second-start/stop against the real compiled btop, the input and blit helpers have precise byte- and cell-level assertions, the agent table test pins launched/pid semantics including the in-process fallback, and the Resources-tab test asserts box framing, the `A` toggle, `q` returning to Sessions, and btop being paused off screen. The retired config tables get a load-compatibility test, and the bump-version script's package/count expectations were updated with the workspace member. I could not verify the vendor/btop C ABI (submodule not in the index), so the FFI-safety and `raw_agents` comments are unproven here, but nothing in the diff shows them to be false. _The code index is behind this pull request (indexed at `be139bbceea3`), so retrieved context may be out of date._

commits

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: The commits lane answered and reported no sensitive content in committed files.
  • Lane summary: No sensitive content in committed files. _The code index is behind this pull request (indexed at `be139bbceea3`), so retrieved context may be out of date._

description

  • Conclusion: Success
  • Scope reviewed: all assigned evidence
  • Positive: The description lane answered that the added CI job and native-deps changes match the PR description, with one gap noted but not reportable on this diff.
  • Lane summary: The added CI job and native-deps changes match the PR description: the new `btop-macos` job uses a pinned checkout (`actions/checkout@v7`) with `dtolnay/rust-toolchain@stable` (a first-party action used the same way throughout this workflow), no untrusted context is interpolated into any `run:` shell, and no `permissions` are widened. The `MEDULLA_BTOP_REQUIRED=1` export via `$GITHUB_ENV` uses no interpolated context. One gap worth noting but not a reportable defect on this diff: the new job writes its btop config under the temp dir; the macOS release build is unaffected, and the diff adds no test assertions worth flagging. No findings. _The code index is behind this pull request (indexed at `be139bbceea3`), so retrieved context may be out of date._
Evidence and run details
  • Models: ladder/vectors-oai3, deepseek-v4.1-flash, deepseek-v4-flash
  • Spend: $0.041484
  • Completion usage: incomplete; some provider completion costs are unavailable.
  • Tokens: 1424560 input · 51686 output · 332032 cached · 826 embedding
  • Updated: 2026-10-29T06:35:16Z
  • Continuity: summary cache chain restarted at the storage ceiling.
Head State Pass summary
be139bbceea3 incomplete 0 active finding(s), 0 resolved finding(s) (at 2026-10-28T19:25:06Z)
89650077732c incomplete 0 active finding(s), 0 resolved finding(s) (at 2026-10-29T06:35:16Z)

tinysweeper 0.1.2

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-10-28T19:24:14.452989Z
We couldn’t complete this review. Comment @codex review to try again.
be139bb PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@tinysweeper tinysweeper 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.

tinysweeper could not complete coverage (36 unanswered item(s)), so this is not an approval.

Diagnostics

Total spend: $0.0232

The build script now distinguishes a missing modern compiler from a usable one and falls back to the unsupported stub with a warning instead of failing, so older toolchains like Debian 12's g++ 12 can still build the workspace. CI lanes set MEDULLA_BTOP_REQUIRED to turn that fallback into a hard error, and the shell test writes its record file atomically to avoid reading a partial file.

Auto-committed-on: cuttlefish
Co-authored-by: Medulla <medulla@tinyhumans.ai>
@senamakel
senamakel merged commit 32908bb into tinyhumansai:main Oct 29, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant