User Troubleshooting Guide
Quick solutions for common issues when using CODITECT framework.
Prerequisites
Before troubleshooting, ensure you have:
- CODITECT environment set up - Completed initial onboarding
- Terminal access - Ability to run bash commands
- Virtual environment available -
.venvdirectory exists - Basic git knowledge - For submodule-related issues
Verify basic setup:
ls .venv/bin/activate # Virtual environment exists
ls .coditect # CODITECT link exists
git status # Git working
Quick Start
Diagnose most issues in 3 steps:
Step 1: Run Diagnostics
# Quick health check
source .venv/bin/activate
./scripts/init.sh
python3 scripts/test-suite.py --quick
Step 2: Check Common Causes
# Verify component activation
python3 scripts/update-component-activation.py list --activated-only | head -10
# Check symlinks
ls -la .coditect .claude
# Verify git status
git submodule status | head -5
Step 3: Apply Solution
Find your specific issue in the sections below and follow the solution steps.
Component Issues
Agent Not Found
Symptom: Claude reports "agent not found" or doesn't recognize agent name.
Solutions:
- Check agent exists:
ls agents/ | grep NAME - Verify activation:
python3 scripts/update-component-activation.py status agent NAME - Activate if needed:
python3 scripts/update-component-activation.py activate agent NAME
Command Not Working
Symptom: Slash command doesn't execute or returns error.
Solutions:
- Check command exists:
ls commands/NAME.md - Verify command syntax in the markdown file
- Check if command requires specific arguments
- Ensure Claude Code CLI is up to date
Skill Not Loading
Symptom: Skill pattern not applied correctly.
Solutions:
- Verify skill path:
ls skills/NAME/SKILL.md - Check for nested skills:
find skills -name "SKILL.md" - Ensure skill is activated in component-activation-status.json
Context Memory Issues
/cx Not Finding Sessions
Symptom: Context extraction finds 0 new messages.
Solutions:
- Check JSONL location:
ls ~/.claude/projects/ - Verify file sizes:
ls -lh ~/.claude/projects/*.jsonl | head - Use min-size filter:
/cx --min-size 1 - Check for exports:
find . -name "*.txt" -path "*/EXPORT*"
/cxq Search Returns Empty
Symptom: Context query returns no results.
Solutions:
- Run extraction first:
/cx - Check database exists:
ls context-storage/sessions.db# ADR-118 Tier 3 - Verify index:
/cxq --knowledge-stats - Try broader search terms
Context Database Corrupted
Symptom: SQLite errors when querying.
Solutions:
- Check backup:
./scripts/backup-context-db.sh --status - Restore from backup:
./scripts/backup-context-db.sh --restore latest - Re-extract if needed:
rm context-storage/sessions.db && /cx# ADR-118
Git Issues
Submodule Detached HEAD
Symptom: Submodule shows "detached HEAD" after update.
Solutions:
cd submodules/affected-submodule
git checkout main
git pull
cd ../..
git add submodules/affected-submodule
git commit -m "Fix detached HEAD"
Git Sync Fails
Symptom: /git-sync reports errors.
Solutions:
- Check git status:
git status - Resolve conflicts manually
- Run in analyze mode first:
/git-sync --mode analyze - Check remote access:
git remote -v
Commit Hook Failures
Symptom: Pre-commit hooks block commit.
Solutions:
- Check hook output for specific error
- Run linting:
npx markdownlint-cli2 "**/*.md" - Fix issues and retry
- Emergency bypass (if needed):
git commit --no-verify(use sparingly)
Python Environment Issues
Module Not Found
Symptom: ModuleNotFoundError when running scripts.
Solutions:
# Activate virtual environment
source .venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Verify Python path
which python # Should show .venv/bin/python
Script Permission Denied
Symptom: Permission denied when running scripts.
Solutions:
chmod +x scripts/script-name.sh
# Or run with Python directly:
python3 scripts/script-name.py
Performance Issues
Slow Context Extraction
Symptom: /cx takes very long.
Solutions:
- Use size filter:
/cx --min-size 10(only files >10MB) - Skip indexing:
/cx --no-index(faster, index later) - Process single file:
/cx specific-file.jsonl
Large Database Size
Symptom: sessions.db exceeds 500MB.
Solutions:
- Backup first:
./scripts/backup-context-db.sh - Consider archiving old messages
- Monitor growth:
ls -lh context-storage/
Quick Diagnostic Commands
# Check component counts
cat config/component-counts.json
# Verify symlinks
ls -la .coditect .claude
# Check git submodule status
git submodule status | head -10
# Verify Python environment
source .venv/bin/activate && python --version
# Check context database (ADR-118 Tier 3)
sqlite3 context-storage/sessions.db "SELECT COUNT(*) FROM messages;"
# Test agent activation
python3 scripts/update-component-activation.py list --activated-only | head -20
Getting Help
- Search context:
/cxq "error message" - Check documentation:
docs/directory - Review ADRs:
internal/architecture/adrs/ - Report issues: https://github.com/coditect-ai/coditect-core/issues
Next Steps
After resolving your issue:
- Document the solution - Use
/cx "fixed [issue]"to capture the fix - Prevent recurrence - Review USER-BEST-PRACTICES.md
- Check related issues - Run the full diagnostic suite
- Report if persistent - File issue at GitHub with reproduction steps
- Share knowledge - Add solution to context for future reference
Related guides:
- USER-BEST-PRACTICES.md - Prevent common issues
- COMPONENT-ACTIVATION-GUIDE.md - Component management
- MEMORY-MANAGEMENT-GUIDE.md - Context preservation
Last Updated: 2025-12-22 Owner: AZ1.AI INC