fix(hooks): check venv cache path before marketplace path #401

Merged
lmiranda merged 1 commits from fix/startup-hook-venv-cache-path into development 2026-02-03 03:15:01 +00:00
Owner

Summary

  • Fixed startup hooks in data-platform and pr-review to check venv cache path first
  • Previously hooks checked marketplace path which gets wiped on updates
  • This caused false "MCP venv missing" errors wasting hours of debugging
  • Updated docs/CANONICAL-PATHS.md with correct venv path pattern

Root Cause

Hooks checked ~/.claude/plugins/marketplaces/.../mcp-servers/.venv/ but venvs live at ~/.cache/claude-mcp-venvs/leo-claude-mktplace/ which survives updates.

Lesson Learned

Wiki: Startup Hooks Must Check Venv Cache Path First

Test Plan

  • Verified venvs exist in cache directory
  • Tested data-platform startup hook - no false "venv missing" error
  • Tested pr-review startup hook - passes silently
  • Copied fixed hooks to installed marketplace

🤖 Generated with Claude Code

## Summary - Fixed startup hooks in `data-platform` and `pr-review` to check venv cache path first - Previously hooks checked marketplace path which gets wiped on updates - This caused false "MCP venv missing" errors wasting hours of debugging - Updated `docs/CANONICAL-PATHS.md` with correct venv path pattern ## Root Cause Hooks checked `~/.claude/plugins/marketplaces/.../mcp-servers/.venv/` but venvs live at `~/.cache/claude-mcp-venvs/leo-claude-mktplace/` which survives updates. ## Lesson Learned Wiki: [Startup Hooks Must Check Venv Cache Path First](https://gitea.hotserv.cloud/personal-projects/leo-claude-mktplace/wiki/lessons/patterns/startup-hooks-must-check-venv-cache-path-first) ## Test Plan - [x] Verified venvs exist in cache directory - [x] Tested data-platform startup hook - no false "venv missing" error - [x] Tested pr-review startup hook - passes silently - [x] Copied fixed hooks to installed marketplace --- 🤖 Generated with [Claude Code](https://claude.com/claude-code)
lmiranda added 1 commit 2026-02-03 03:14:41 +00:00
Startup hooks in data-platform and pr-review were checking for venvs
at the marketplace path (~/.claude/plugins/marketplaces/.../mcp-servers/)
which gets wiped on updates. The actual venvs live in the cache directory
(~/.cache/claude-mcp-venvs/) which survives updates.

This caused false "MCP venv missing" errors even when venvs existed,
wasting hours of debugging time.

Fixed hooks now check cache path first, matching the pattern used
by run.sh scripts.

Also updated docs/CANONICAL-PATHS.md with the correct venv path pattern
to prevent future occurrences.

Lesson learned: lessons/patterns/startup-hooks-must-check-venv-cache-path-first

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
lmiranda merged commit 39556dbb59 into development 2026-02-03 03:15:01 +00:00
lmiranda deleted branch fix/startup-hook-venv-cache-path 2026-02-03 03:15:02 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: personal-projects/leo-claude-mktplace#401