-
Notifications
You must be signed in to change notification settings - Fork 284
Setup Wizard: Multiple Bugs #22
Description
Hi @parcadei thank you for your incredible job!
I'm new to coding and have hard time installing the script. tried to fix it with claude with no luck. Decided to generate report at the end, maybe it will help.
#19 this issue might help in my case, waiting for it to be merged to test.
Setup Wizard: Multiple Critical Bugs
Environment
- OS: macOS (Darwin 25.0.0)
- Python: 3.11+
- Package Manager: uv
Bug Summary
The setup wizard has 3 critical bugs that prevent successful installation:
Bug 1: Docker Health Check Fails (Fixed ✅)
Location: opc/scripts/setup/docker_setup.py:74-129
Problem: wait_for_services() doesn't use -f flag for docker compose commands, causing health checks to fail.
Error:
Start Docker stack (PostgreSQL, Redis)? [y/n] (y): y
OK Docker stack started
Waiting for services to be healthy...
WARN Some services may not be healthy
Root Cause: The function runs docker compose ps without specifying the compose file:
# Before (buggy):
docker compose ps postgres --format "{{.Health}}"
# After (fixed):
docker compose -f /path/to/docker-compose.yml ps postgres --format "{{.Health}}"Fix Applied: Added compose_file parameter and -f flag to health check commands.
Bug 2: Database Migrations Fail (Fixed ✅)
Location: opc/scripts/setup/docker_setup.py:132-231
Problem: run_migrations() has multiple issues:
- Missing
-fflag for docker compose commands - Wrong database name:
claude_continuityinstead ofcontinuous_claude - Wrong init SQL filename:
init-db.sqlinstead ofinit-schema.sql
Error:
Step 6/12: Database Setup
Run database migrations? [y/n] (y): y
ERROR service "postgres" is not running
Root Cause: Migrations use wrong database name and missing compose file flag:
# Before (buggy):
"-d", "claude_continuity" # Wrong DB name
# No -f flag
# After (fixed):
"-d", "continuous_claude" # Correct DB name
"-f", str(compose_path) # Added compose fileFix Applied:
- Changed database name from
claude_continuitytocontinuous_claude - Added
-fflag with compose file path - Changed init SQL filename from
init-db.sqltoinit-schema.sql
Bug 3: Hooks/Skills Not Installed to Global Claude Config (Fixed ✅)
Location: opc/scripts/setup/wizard.py:495
Problem: Wizard installs to project-local .claude/ instead of global ~/.claude/.
Root Cause:
// Line 495 in wizard.py (WRONG):
claude_dir = get_claude_dir() // Returns Path.cwd() / ".claude" (project-local)
// Should be:
claude_dir = get_global_claude_dir() // Returns Path.home() / ".claude" (global)Impact: Hooks and skills are installed to the repo folder where Claude Code doesn't look for them. They must be in ~/.claude/ to work.
Fix Applied: Changed get_claude_dir() to get_global_claude_dir() in wizard.py:495
Bug 4: Sandbox CLI Warning (Expected, Not a Bug)
Location: opc/scripts/setup/wizard.py:452-465
Note: The "WARN Sandbox CLI returned error" is expected - the opc status CLI doesn't exist yet. It's a planned feature.
Steps to Reproduce
- Clone repo:
git clone https://github.com/flashwing-nwrp/Continuous-Claude-v3 - Run setup wizard:
cd opc && uv run python -m scripts.setup.wizard - Accept all defaults
- Observe errors at Steps 5 and 6 (Docker health and migrations)
- After wizard completes, check:
ls ~/.claude/hooks/(empty/missing files)ls ~/.claude/skills/(empty)- Hooks and skills are in repo's
.claude/instead
Expected Behavior
- Docker health check should pass ✅ (Fixed)
- Migrations should run successfully ✅ (Fixed)
- Hooks/skills should install to
~/.claude/(global config) ✅ (Fixed) - Claude Code should load OPC hooks and skills automatically ✅ (Now works)
Additional Notes
- Docker Desktop restart was needed due to hung daemon (not a code bug)
- The setup wizard backs up global
~/.claude/but doesn't install to it - Functions
get_global_claude_dir()andget_claude_dir()both exist, but wizard uses the wrong one
Workarounds
For Bug 3 (hooks/skills), manually copy:
cp -r /path/to/repo/opc/.claude/* ~/.claude/Files That Need Fixes
- ✅
opc/scripts/setup/docker_setup.py- Fixed (Docker health check + migrations) - ✅
opc/scripts/setup/wizard.py- Fixed (Line 495 now usesget_global_claude_dir())
P.S. even when I copy skills hooks etc to global folder hooks are not wokring both local and global folder.
Folder:
~/Repos/Continuous-Claude-v3/opc
⎿ SessionStart:startup hook error
⎿ SessionStart:startup hook error
⎿ SessionStart:startup hook error
❯ hi
⎿ UserPromptSubmit hook error
⎿ UserPromptSubmit hook error
⎿ UserPromptSubmit hook error
⎿ UserPromptSubmit hook error
⏺ Hi! How can I help you today?
⏺ Ran 4 stop hooks
⎿ Stop hook error: Failed with non-blocking status code: bash:
/Users/admin/Repos/Continuous-Claude-v3/opc/.claude/plugins/braintrust-tracing/hooks/stop_hook.sh: No such file or directory
⎿ Stop hook error: Failed with non-blocking status code: node:internal/modules/cjs/loader:1386
throw err;
^
Error: Cannot find module '/Users/admin/Repos/Continuous-Claude-v3/opc/.claude/hooks/dist/compiler-in-the-loop-stop.mjs'
at Function._resolveFilename (node:internal/modules/cjs/loader:1383:15)
at defaultResolveImpl (node:internal/modules/cjs/loader:1025:19)
at resolveForCJSWithHooks (node:internal/modules/cjs/loader:1030:22)
at Function._load (node:internal/modules/cjs/loader:1192:37)
at TracingChannel.traceSync (node:diagnostics_channel:322:14)
at wrapModuleLoad (node:internal/modules/cjs/loader:237:24)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:171:5)
at node:internal/main/run_main_module:36:49 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v22.20.0