Commit Graph
292 Commits
Author SHA1 Message Date
AIOSAIandClaude Opus 4.6 cf0bf34276 fix(seedgo): short-circuit __init__.py in imports + naming checkers
Empty __init__.py files were failing both checkers as false positives:
- imports: zero-check result scored 0% and reported "Failed (no details)"
- naming: __init__ fails snake_case regex ^[a-z][a-z0-9_]*$

Python package markers don't require imports by convention and cannot
be renamed (Python-reserved). Short-circuit both checkers to return
PASS for any file named __init__.py.

Reported by @devpulse while adding navigator/__init__.py to compass.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-14 21:58:16 -07:00
AIPassand@devpulse 5d3935a720 feat(system): prax status sync: drop minute precision from STATUS.md timestamp — date-only (agents already get current time injected every turn, minute precision was causing phantom diffs on every sync within a new minute) (#278)
Co-authored-by: @devpulse <devpulse@aipass>
2026-04-14 21:53:08 -07:00
AIOSAIand@drone caf2bf59a0 feat(drone): S92 regression: unstage .git_pr.lock after git add -A in system-pr
Co-Authored-By: @drone <drone@aipass>
2026-04-14 21:11:26 -07:00
AIOSAIand@devpulse 01162bb2d5 feat(system): watchdog module + identity framing revision + private project scrub — FPLAN-0186 shipped (130 tests, 5 handlers, agent/timer/schedule/registry + multi-watch mgmt), devpulse identity updated (designer + light builder + primary collaborator, CWD-is-identity principle), full scrub of private personal memory project from public repo
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 20:38:20 -07:00
AIOSAI 22d6d98707 Merge remote-tracking branch 'origin/main' 2026-04-14 20:37:53 -07:00
AIPass 487c58e452 Merge pull request #268 from AIOSAI/fix/wake-claude-path-resolution
fix(wake): resolve claude binary by absolute path for restricted-PATH environments
2026-04-14 20:14:12 -07:00
AIPass 9d80a5e121 Merge pull request #267 from AIOSAI/fix/issue-261-windows-compat
fix(init,setup): Windows compatibility — issue #261 (three blockers)
2026-04-14 20:13:40 -07:00
AIOSAIand@devpulse e263d56178 feat(system): feat(skills): split /memo and /prep handling — memo user-scope only, prep ships via aipass init template with STATUS.local.md promotion
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 13:51:09 -07:00
AIOSAIandClaude Sonnet 4.6 6c025a042b fix(prax): AIPL polyglot log leak — path resolver + regression tests (DPLAN-0125 Track G)
Root cause: get_module_logs_dir() last fallback unconditionally created
src/aipass/{name}/logs/ for any unknown module name, causing AIPL polyglot
agents (running with AIPASS_HOME set for cross-project access) to dump logs
into src/aipass/unknown_branch/logs/ inside the AIPass source tree.

Fix in apps/handlers/config/load.py:
- Check AIPASS_CALLER_CWD env var (set by drone during cross-project dispatch,
  DPLAN-0121) and walk up to caller project root (.git or pyproject.toml)
- Final fallback: system_logs/external/{module_name} — never creates unknown
  directories in ECOSYSTEM_ROOT
- Added inspect.stack() auto-detection when module_name is not provided
- Added _warn_routing() helper for lazy prax logger access (avoids circular
  import: logger.py imports load.py at module level)

Also in this PR:
- Regression tests: test_unknown_module_routes_to_system_logs_external and
  test_aipass_caller_cwd_routes_to_caller_project (38 tests, all green)
- bypass.json: architecture + documentation exemptions for tests/test_config.py

Cleanup (done separately on main): 27 leaked AIPL polyglot logs moved from
src/aipass/unknown_branch/ to /tmp/aipl_leaked_logs/; directory removed.

CC @polyglot: if AIPL sets AIPASS_CALLER_CWD during drone dispatch, logs will
route to ~/Projects/AIPL/ automatically. No AIPL changes required for the base
fix — the system_logs/external/ fallback already prevents pollution.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-14 13:29:57 -07:00
AIOSAIandClaude Sonnet 4.6 efc0056be8 fix(prax): AIPL polyglot log leak — path resolver fix + regression tests (DPLAN-0125 Track G)
Root cause: get_module_logs_dir() last fallback unconditionally created
src/aipass/{name}/logs/ for any unknown module, causing external projects
(AIPL polyglot) running with AIPASS_HOME set to pollute the AIPass src tree
with src/aipass/unknown_branch/logs/*.

Fix (already committed in 3c5ac29):
- Check AIPASS_CALLER_CWD env var (set by drone during cross-project dispatch,
  DPLAN-0121) and walk up to the caller's project root (.git/pyproject.toml)
- Final fallback: system_logs/external/{module_name} — never create unknown
  dirs in the AIPass source tree
- Added inspect.stack() auto-detection when module_name is not provided
- Added _warn_routing() helper for lazy prax logger access (avoids circular
  imports — logger.py imports load.py at module level)

This PR:
- Regression tests: test_unknown_module_routes_to_system_logs_external and
  test_aipass_caller_cwd_routes_to_caller_project (both green)
- Cleanup: moved 27 leaked AIPL polyglot logs from src/aipass/unknown_branch/
  to /tmp/aipl_leaked_logs/ for AIPass Developer review; removed directory
- bypass.json: architecture + documentation exemptions for tests/test_config.py

CC @polyglot: AIPL-side logger config may need AIPASS_CALLER_CWD set during
cross-project dispatch so logs route to ~/Projects/AIPL/ correctly. The fix
is transparent if drone sets AIPASS_CALLER_CWD; no AIPL changes required for
the basic fix, but explicit env var support improves log placement accuracy.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-14 13:28:06 -07:00
AIOSAIand@devpulse 2e41b75fe9 feat(system): Compass devpulse personal layer scaffold (DPLAN-0125 Track I): triple-layer gitignore protection, compass_wrapper.py stub (query_top/ingest_learning/stats signatures), seedgo bypass entries. Design doc at devpulse/.trinity/night_shift_reports/compass_layer_design.md. Scaffold ready for future implementation session.
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 06:33:50 -07:00
AIOSAIand@devpulse 3c5ac29fba feat(system): Personal-name scrub: Patrick -> user / AIPass Developer across public repo
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 06:14:03 -07:00
AIOSAIandClaude Sonnet 4.6 98191fa97e fix(wake): resolve claude binary by absolute path for restricted-PATH environments
Background processes (trigger Medic, prax watchdog) inherit a restricted PATH
that omits ~/.local/bin, causing FileNotFoundError when wake_branch() tries to
spawn claude (pip-installed at ~/.local/bin/claude).

Fix: add _find_claude_bin() to locate claude via shutil.which() with fallback
to known install paths; use _CLAUDE_BIN constant in both fresh/resume commands;
explicitly prepend ~/.local/bin to spawn_env PATH in both wake.py and
dispatch_monitor.py. Confirmed by logs: 'Failed to spawn @trigger/@flow:
[Errno 2] No such file or directory: claude'.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-14 02:56:12 -07:00
AIOSAIandClaude Sonnet 4.6 2ec5ec1a86 fix(init,setup): Windows compatibility — issue #261 (three blockers)
BLOCKER 1 (bootstrap.py): Replace bash dirname/while loop in _claude_settings()
with a cross-platform python3 -c one-liner using pathlib.Path.parents. The bash
loop broke on Windows because root is 'C:\' not '/'. Python pathlib handles all
OS path separators correctly.

BLOCKER 2 (setup.sh): Add OS detection (IS_WINDOWS via OSTYPE/uname). On Windows
(Git Bash/MSYS2/Cygwin), skip the sudo ln -sf symlink step and print manual
PATH-extension instructions for PowerShell, CMD, and Git Bash. Also make venv
activation OS-aware (Scripts/activate on Windows, bin/activate elsewhere).

BLOCKER 3 (setup.py): New cross-platform Python installer at repo root. Does
everything setup.sh does — create venv, install editable, verify entry points,
seed secrets dir, .env, registry, bootstrap branch identity files — and works
natively on Windows without Git Bash. Uses sys.executable (no python3 vs python
ambiguity), pathlib throughout, and prints PATH instructions on Windows instead
of attempting symlink creation.

Closes #261.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-14 02:43:31 -07:00
AIOSAIand@drone 181145be54 feat(drone): S91 three bugs: git add -A, STATUS.md sync before commit, Rich help formatting
Co-Authored-By: @drone <drone@aipass>
2026-04-14 02:31:17 -07:00
AIOSAIand@devpulse 2fd70c4902 feat(system): devpulse docs restructure: lean README (209→35 lines) + new SETUP.md with install/uninstall/troubleshooting for Linux/macOS/Windows (WSL), env vars reference, Windows native support tracking via issue #261
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 02:20:11 -07:00
AIOSAIand@devpulse c27cc4ab11 feat(system): S91 cleanup round 2: S90 stragglers staged (ai_mail contacts/identity, devpulse feedback channel, prax monitor_info)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 01:38:56 -07:00
AIOSAIand@devpulse 6958cfe28f feat(system): S91 cleanup: AIPass Developer scrub, S90 stragglers, README presence epigraph, trigger lock gitignore
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-14 01:36:05 -07:00
AIOSAIand@devpulse e73abb8f8b feat(system): S90: fix cross-project email — sender detection + caller registry target resolution
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-12 01:02:35 -07:00
AIOSAIand@devpulse 46d80093d1 feat(system): S90: ai_mail contacts-based resolution (DPLAN-0121 Phase 5) — replaces env var branch detection
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 22:49:47 -07:00
AIOSAIand@devpulse cb9c39f400 feat(system): S90: prax Ctrl+C clean exit + UNKNOWN labels fix + AI_MAIL label fix (DPLAN-0118 complete)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 21:25:55 -07:00
AIOSAIand@devpulse 5931952c2b feat(system): S90: local prompt hook injection + prax trigger dead code removal (Vera BUG-4 fix)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 18:34:45 -07:00
AIOSAIand@devpulse b62e9784c1 feat(system): S90: prax dead trigger code removal + filesystem handler cleanup
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 18:26:23 -07:00
AIOSAIand@devpulse 262bb7bb58 feat(system): S90: ai_mail bidirectional cross-project email (DPLAN-0121 Phase 3) + reply-path delivery
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 18:15:37 -07:00
AIOSAIand@devpulse e7950e76f9 feat(system): S90: drone JSON fix + cli AIPASS_HOME auto-detect + mailbox + prax monitor refactor + test isolation
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 18:00:43 -07:00
AIOSAIand@devpulse 1f900bcbbb feat(system): S89: prax branch_detector cleanup (parameter rename, logging)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 15:48:55 -07:00
AIOSAIand@devpulse 55cf149a95 feat(system): S89: ai_mail view latest + ANSI TTY detection + auto-watchdog hook (DPLAN-0119)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 15:41:24 -07:00
AIOSAIand@devpulse 36a0f4a894 feat(system): S89: prax monitor colors + UNKNOWN fix (project colors, test attribution, external project detection)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 15:22:28 -07:00
AIOSAIand@devpulse 4410138973 feat(system): S89 follow-up: prax three-tier monitor labels (DPLAN-0118) — PROJECT/AGENT/MODEL format for multi-project ecosystem
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 15:16:17 -07:00
AIOSAIand@devpulse e8a9af4bc0 feat(system): S89: full external access (AIPASS_HOME dual registry) + feedback channel (cross-project bridge) + init update idempotency
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 14:49:16 -07:00
AIOSAIandClaude Sonnet 4.6 5b2d14a846 fix(trigger): correct SYSTEM_LOGS_DIR path in watchers and startup
TRIGGER_ROOT.parent.parent resolves to src/, not the project root.
Fix to TRIGGER_ROOT.parent.parent.parent so all three SYSTEM_LOGS_DIR
constants resolve to /home/patrick/Projects/AIPass/system_logs.
Fixes recurring 'Failed to start log watcher' on every service start.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-11 10:22:36 -07:00
AIOSAIand@devpulse 079cb3e94e feat(system): S87: model choice for dispatch + DPLAN-0114 (aipass init update) + Compass decisions + Patrick-Personal deny rules
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-11 01:36:03 -07:00
AIOSAIand@devpulse 6d34836748 feat(system): S86: memory bypass update + trigger dead code removal (10 orphaned functions from DPLAN-0112)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 16:44:44 -07:00
AIOSAIandClaude Opus 4.6 4cf1b327dc refactor(trigger): remove dead code from error_logged.py after monitor-only conversion
Removed 10 orphaned functions/constants left after DPLAN-0112 Option C stripped
dispatch: _find_repo_root, _is_medic_enabled, _is_branch_muted,
_get_registered_emails, _is_rate_limited, _record_dispatch, _log_suppression,
_build_notification_message, and associated constants. Handler now only uses
_log_warning + json_handler. 370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 16:43:10 -07:00
AIOSAIand@devpulse 612a6f5afa feat(system): S86: drone unused_function fix — refresh_external_modules wired to public API
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 16:40:26 -07:00
AIOSAIand@devpulse 6cfceee49d feat(system): S86: ai_mail naming bypass + STATUS sync
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 16:31:49 -07:00
AIOSAIand@devpulse bd24c65dfd feat(system): S86: cli test_quality fix + drone/trigger seedgo bypass updates
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 16:27:58 -07:00
AIOSAIandClaude Opus 4.6 0199356b5b fix(trigger): update seedgo bypass line numbers for error_handling standard
Line numbers shifted after DPLAN-0112 code changes. Updated 6 bypass entries:
config.py 31→36, core.py 160→61, json_handler.py 24→31, error_detected.py
54→53, plan_file.py 58→59, memory_threshold_exceeded.py 46→47. All are
pre-existing meta-logging _log_warning() except:pass patterns.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 16:26:16 -07:00
AIOSAIandClaude Opus 4.6 f626a0411c fix(trigger): fix silent_catch violations — add logging + bypass entries
Fixed log_watcher.py:584 lazy registry import fallback (was except:pass,
now logs warning). Added seedgo bypass entries for intentional patterns:
core.py (ImportError fallback, type coercion), config.py (meta-logging,
tmp cleanup, ImportError fallback), log_watcher.py (timestamp format loop).
370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 16:20:42 -07:00
AIOSAIand@devpulse d9fe1ad38b feat(system): S86: drone debug_print fix + memory encapsulation bypasses + STATUS sync
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 16:10:27 -07:00
AIOSAIandClaude Opus 4.6 1cc07b3ca2 refactor(trigger): fix deep_nesting in _load_circuit_breaker_state
Extracted _restore_fingerprint_tracking() helper and flattened early-return
guards to reduce nesting depth from 5 to 3. Seedgo deep_nesting now passes.
370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 16:03:10 -07:00
AIOSAIand@devpulse 6a127b066d feat(system): S86: api catch-all logger + STATUS sync
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 15:59:33 -07:00
AIOSAIand@devpulse 75645d2747 feat(system): S86: cleanup — json_handler noise fix, prompt tightened, plugins README, STATUS branches count
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 15:49:21 -07:00
AIOSAIandClaude Opus 4.6 59490757ca feat(trigger): DPLAN-0112 #4 — per-handler failure counting + auto-disable
_fire_to_handlers now tracks consecutive failures per handler. After 5
consecutive failures, the handler is auto-disabled (skipped) and a CRITICAL
log is emitted. Success resets the failure count. Disabled handlers re-enable
on process restart (in-memory tracking). Prevents broken handlers from
flooding logs forever. 370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 14:56:48 -07:00
AIOSAIandClaude Opus 4.6 24568eb208 feat(trigger): DPLAN-0112 #3 — full circuit breaker persistence to trigger_cb_state.json
Moved CB state from trigger_config.json to dedicated trigger_cb_state.json.
Now persists full state: recent_errors timestamps, half_open_allow, summary_sent,
and per-fingerprint dispatch tracking (last_dispatch + count). Restored on
startup. record_dispatch() now triggers persist. Uses atomic_write_json +
json_file_lock. Module-level dict init moved before CB load so fingerprint
data restores correctly. 370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 14:54:05 -07:00
AIOSAIandClaude Opus 4.6 e4a7c04a2b feat(trigger): DPLAN-0112 #2 — fcntl file locking on JSON state files
Added json_file_lock() context manager to config.py using fcntl.flock
with .lock sidecar files. Wrapped all read-modify-write cycles:
- error_registry.py: report(), _save/_clear_circuit_breaker_state()
- medic_state.py: set_enabled(), mute_branch(), unmute_branch()
- log_watcher.py: _save_seen_hashes(), _save_log_positions()
Combined with existing atomic_write_json for both concurrency and crash safety.
370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 14:50:51 -07:00
AIOSAIand@devpulse 09315827f9 feat(system): S86: drone deep_nesting fix — fix_git_state refactored (last seedgo gap)
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 14:43:27 -07:00
AIOSAIand@devpulse 0350fa20ca feat(system): S86: seedgo quality — silent_catch + deep_nesting fixes (5 branches) + trigger error_logged refactor + prompt fixes
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 14:35:51 -07:00
AIOSAIandClaude Opus 4.6 0c290a95d1 fix(trigger): DPLAN-0112 Option C — strip dispatch from error_logged, route through Medic v2
error_logged.py handler stripped to monitor-only (log event, no email/dispatch).
Centralized watcher (watchers/log_watcher.py) now calls registry_report() +
fires error_detected for ERROR-level lines, routing through full Medic v2
pipeline (count threshold, circuit breaker, fingerprint backoff). Falls back
to error_logged (monitor-only) if registry unavailable. 370 tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-10 14:28:11 -07:00
AIOSAIand@devpulse 64c74a5a2f feat(system): S86: docs accuracy — HERALD S83-S86 milestones, STATUS counts, demo/devpulse.py fixes
Co-Authored-By: @devpulse <devpulse@aipass>
2026-04-10 14:19:38 -07:00