.maestro/playbooks/2026-02-23-Issue-Triage/2026-02-23-Root-Cause-Fixes/TRIAGE-09-Minor-Fixes-And-Cleanup.md
These are lower-priority items that don't affect core functionality. The "security" issues are mostly theoretical for a localhost-only application. The project name collision was already addressed in Phase 03. What remains: preventing CLAUDE.md from being written into .git/ (which corrupts refs), respecting the plugin disabled state, and cleaning up remaining edge cases.
Issues resolved: #1165 (.git corruption), #781 (plugin disabled not respected), #923 (slow loading), #1079 (context re-injection), #1099 (stale AbortController)
Prevent CLAUDE.md creation inside .git/ directories (#1165):
CLAUDE.md or AGENTS.md filesif (resolvedPath.includes('/.git/') || resolvedPath.includes('\\.git\\')) returnisInsideGitInternals() utility module.git/ path guard to all 4 write sites: writeClaudeMdToFolder() in claude-md-utils.ts, writeAgentsMd() in agents-md-utils.ts, writeClaudeMdToFolder() in claude-md-commands.ts, writeClaudeMdToFolderForRegenerate() in regenerate-claude-md.ts. 4 new tests added. Commit 2616ac09.Fix plugin disabled state not being respected (#781):
~/.claude/settings.json and check for a disabled plugins listsrc/shared/plugin-state.ts with isPluginDisabledInClaudeSettings() — checks enabledPlugins["claude-mem@thedotmack"] === false in Claude Code's settings.json. Added early exit to: worker-service.ts:main() (gates start/hook/restart/daemon commands), bun-runner.js (before spawning Bun), smart-install.js (before dependency checks). 7 new tests. 1070/1070 pass. Commit d6bc4495.Fix UserPromptSubmit injecting context on every turn (#1079):
UserPromptSubmit, not just the first promptcontextInjected flag to /api/sessions/init response — checks SessionManager.getSession(sessionDbId) to detect if SDK agent is already running. session-init.ts hook handler now skips POST /sessions/{sessionDbId}/init (SDK agent re-initialization) when contextInjected=true. Prompt tracking via /api/sessions/init still runs on every turn. 6 new tests. 1076/1076 pass.Fix stale AbortController queue stall (#1099):
AbortController usage in the codebaseAbortSignal.timeout(30000) to prevent indefinite stallslastGeneratorActivity timestamp to ActiveSession — updated by processAgentResponse() (all agents), getMessageIterator() (queue yields), and startGeneratorWithProvider() (generator launch). (2) Added stale generator detection in SessionRoutes.ensureGeneratorRunning() — if lastGeneratorActivity exceeds 30s threshold, aborts stale controller, resets generator state, and starts fresh. (3) Added AbortSignal.timeout(30000) in SessionManager.deleteSession() — prevents indefinite hang when awaiting a stuck generator promise. 10 new tests. 958/958 pass (24 pre-existing failures unrelated to this change). Run npm test and fix any failures