fix(kkernel): honor the selected config through exec, local fallback, and replay - #1298
Draft
ohdearquant wants to merge 2 commits into
Draft
fix(kkernel): honor the selected config through exec, local fallback, and replay#1298ohdearquant wants to merge 2 commits into
ohdearquant wants to merge 2 commits into
Conversation
added 2 commits
July 22, 2026 10:31
… and replay kkernel exec did not bind --config/KHIVE_CONFIG; initial runtime resolution, the inline and ops-file local fallback topology reloads, and pending-event replay all reloaded configuration with standard discovery, so a secondary instance with an overridden config could write creates into the HOME-derived default database. The selected config now flows through every one of those layers, making the backend topology identical across resolution, fingerprinting, dispatch, and replay. Closes #1246.
kkernel exec --config now spawns the daemon with the same --config path, so both sides resolve identical TOML topology and their config_id fingerprints match; regressions cover argv construction and the strict auto-spawn path.
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
kkernel execnow honors--config/KHIVE_CONFIGthrough every layer: initial runtime resolution, inline and ops-file local-fallback topology reloads, and pending-event replay. Previously a secondary instance whose config selected an isolated backend could fall back to the HOME-derived default database for creates.Closes #1246
Changes
crates/kkernel/src/exec.rs: bind the config selector onExecArgs; carry it through initial resolution,ExecDbContextreloads, and pending-event replay.crates/khive-mcp/src/pending_events.rs: config-aware pending-event entry point; selected config flows into programmatic MCP server construction.config_env_db_isolation.rs: two independent temp stores; create viakkernel execwithKHIVE_CONFIGset must land in the override store only ((1, 0)).Verification
kkernelexec tests (54),khive-mcppending_events tests (30), fmt, clippy-D warnings,cargo check --workspaceall green.