fix: split made_edit_or_build_check into separate flags and minor whitespace cleanup#288
Merged
Scott McMaster (scottmcmaster) merged 1 commit intoJun 4, 2026
Conversation
Collaborator
Author
Copilot started reviewing on behalf of
Scott McMaster (scottmcmaster)
June 3, 2026 07:10
View session
made_edit_or_build_check into separate flags and minor whitespace cleanup
This was referenced Jun 3, 2026
Closed
Closed
Juanpe Bolívar (arximboldi)
approved these changes
Jun 3, 2026
Juanpe Bolívar (arximboldi)
left a comment
Contributor
There was a problem hiding this comment.
LGTM!
(Reviewing through Graphite, giving this whole stack thing another try).
834dc3b to
0c09458
Compare
Contributor
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the Rust evolution loop (apps/native/src-tauri/src/evolve/mod.rs) to track “made an edit” vs “ran a build check” as separate flags, and adjusts how evolution limits are loaded to help address a build issue on develop.
Changes:
- Split the previous combined “edit or build check happened” tracking into two booleans:
made_editandmade_build_check. - Refactor evolution limit loading (notably moving
max_output_tokensto be read viastore::get_max_output_tokens, and loadingmax_build_attemptsviaconfig::EvolutionLimits::load). - Minor whitespace/comment cleanup.
Comment on lines
29
to
31
| // Re-export public API | ||
| use crate::shared_types::EvolutionState; | ||
| use crate::shared_types::{Evolution, EvolutionState, FileEdit}; | ||
| use crate::system::nix; |
cooper (czxtm)
pushed a commit
that referenced
this pull request
Jun 4, 2026
3 tasks
cooper (czxtm)
added a commit
that referenced
this pull request
Jun 6, 2026
* Improve nixos/home-manager/nix-darwin doc tool Improves doc tool by splitting up large JSON into a hierarchical directory structure, and adds an index at the root containing a table of contents and short info about each key. This reduces context usage in the same way that the index in skills does. The tools is also split up into two separate tools, one for searching keys, and one for getting more info about that key. * chore: fix merge pr 255 (#292) * feat(console): add resizable log panel * feat(state): wire runtime slices and summarizer * chore(fmt): add treefmt wiring * chore(credentials): remove legacy plaintext fallback * ci: add evaluate workflow * fix(theme): scope Minted to Monaco diffs * feat(settings): split backup and tuning panels * refactor(frontend): move backend mirrors to viewmodel * chore(beads): update state migration issues * fix: repair branch-wide breakage so the merge compiles & tests pass Prior to this commit, both this branch (since a92e61b) and the merge result failed `cargo check` with 22 errors. The user asked for cargo + bun validation against the merge resolution, so this commit fixes the preexisting structural breakage that the merge inherited, plus a few follow-ups uncovered by the test suites. Rust: - git/mod.rs: restore the develop-side mod.rs that declares `pub mod query` / `pub mod init` and re-exports the right names from each. The orphan query.rs / init.rs files were already on disk; only the mod entry was missing after a92e61b accidentally gutted it. - evolve/mod.rs: route `repo_root` through `git::query` (its new home), pull `FileEdit` from `shared_types`, re-export `Evolution` from `shared_types::Evolution` (types.rs only imports it, doesn't re-export it), and fix the `made_edit_or_build_check` typo that develop's PR #272 introduced (variable never defined; should be `made_edit || made_build_check`). - shared_types/git.rs: re-add `WatcherEvent` alongside the unused `GitState` slice type — `state/watcher.rs` still constructs it and needs the symbol back. Marked `GitState` `#[allow(dead_code)]` until the watcher migration finishes. - summarize/queue_summarizer.rs: `#[allow(dead_code)]` on the not-yet-wired worker scaffolding (a92e61b carryover). - commands/settings_io.rs: update an EvolutionLimits test fixture to include the new `max_token_budget` / `max_output_tokens` fields. Frontend (post-merge tweaks): - ipc/api.ts: drop the duplicate `devConfigs` entry the auto-merge produced (it appeared once near `settings` and again after `promptHistory`). - ipc/types.ts: regenerated via `cargo run --example specta_gen_ts` to drop duplicated `ConfigField` / `ConfigurableSchema` / `EnumVariant` / `FieldType` blocks the auto-merge dual-inserted. - viewmodel/git.ts + viewmodel.test.ts: switch the `git_state_changed` payload type from `GitState` (unused TS-side) to `WatcherEvent` (what the Rust watcher actually emits). - hooks/use-evolve.ts: drop the eager `mirrorChangeMapState(null)` at the top of `handleEvolve`. Line 109 already correctly avoids overwriting the change map for conversational responses; the eager clear contradicted that and broke develop's PR #243 test that exercises conversational follow-ups. - Tests (`use-evolve.test.ts`, `use-rollback.test.ts`, `prompt-input.test.tsx`, `system-defaults-cta.test.tsx`): swap the removed `setGitStatus` / `setEvolveState` / `setChangeMap` / `setSummaryAvailable` widget-store setters for the viewmodel mirror fns (`mirrorGitState`, `mirrorEvolveState`, `mirrorChangeMapState`). `summaryAvailable` no longer exists on the widget store; the related assertions are dropped. - Storybook snapshots: 30 stories were regenerated after the AI Models tab field split, the system-defaults icon swap, and the hunk-pill render going through `DiffLineStatsBadge`. Validation: - `cargo check`: clean - `cargo test`: 366 passed - `bun run test:unit`: 116 passed - `bun run test:storybook`: 165 passed - `bun run build` (tsc + vite): clean Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * fix signing * refactor: restore slice-event-per-slice contract in watcher The earlier repair commit (8a19689) brought back `WatcherEvent` to make state/watcher.rs compile, but that struct bundles four slices' worth of state (git_status, change_map, evolve_state, error) onto the `git_state_changed` channel. The intended architecture is one event per slice, each carrying just that slice's state. Watcher now emits: - `git_state_changed` → GitState { git_status, external_build_detected } - `change_map_changed` → SemanticChangeMap (unchanged) - `evolve_state_changed` is no longer emitted from the watcher at all; evolve_state::set() writes through Slice<EvolveState>, whose write-guard already emits the event on drop. The watcher was emitting it twice. Drop WatcherEvent from shared_types/git.rs and from the specta registration; the `#[allow(dead_code)]` on GitState becomes unnecessary. Separately, queue_summarizer's three #[allow(dead_code)] annotations were honest: the commit a92e61b ("feat: wire runtime slices and summarizer") never actually wired the worker — `app.manage(start_worker(handle)?)` was missing from main.rs. Adding it now so the pipelines' `try_state::<SummarizerState>()` path is actually used instead of always falling back to inline processing. Frontend follow-ups: - viewmodel/git.ts subscribes `git_state_changed` as `GitState` now. - viewmodel.test.ts constructs `GitState` (2 fields), not the made-up 5-field WatcherEvent. - types.ts regenerated via `cargo run --example specta_gen_ts`. Validation: cargo check clean, 366 cargo tests pass, 116 unit tests pass, tsc + vite build clean. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * fix: some permission tests would fail on CI Replace with more effective and reproducible tests. --------- Co-authored-by: Cooper Maruyama <me@cooperm.com> Co-authored-by: cooper <1325802+czxtm@users.noreply.github.com> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * scott-fix-made-edit-or-build-check (#288) * ci(danger): use Node.js for coverage and danger steps Bun 1.3.2 cannot run @vitest/coverage-v8 (node:inspector not implemented) and fails to resolve Danger's internal runner module ('Script not found "runner"'). Switch both the coverage generation and the danger ci steps to npx (Node.js 22) while keeping bun for dependency installation. Also adds statuses:write permission so Danger can set commit statuses. * Improve nixos/home-manager/nix-darwin doc tool Improves doc tool by splitting up large JSON into a hierarchical directory structure, and adds an index at the root containing a table of contents and short info about each key. This reduces context usage in the same way that the index in skills does. The tools is also split up into two separate tools, one for searching keys, and one for getting more info about that key. --------- Co-authored-by: Juanpe Bolívar <raskolnikov@gnu.org> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com> Co-authored-by: Scott McMaster <scott@smcmaster.com> Co-authored-by: darkmatter[bot] <283346107+darkmatter[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
"made edit" and "made build check" are tracked separately again (or now); this is to try and fix the build on
developTest Plan
Docs
Need help on this PR? Tag
/codesmithwith what you need. Autofix is disabled.