Commit Graph
425 Commits
Author SHA1 Message Date
haelyra ecf2f31cb7 Merge PR #3476: select native Windows shell paths 2026-10-10 17:39:48 -04:00
haelyra 54a9278560 Merge PR #3464: identify hooks by their input sessions 2026-10-10 17:38:00 -04:00
haelyra 41ce11d889 Merge PR #3456: adapt manual Claude component references 2026-10-10 17:37:42 -04:00
haelyra 27875bfd02 Merge PR #3444: track OpenCode skill runs and report measurement gaps 2026-10-10 17:37:11 -04:00
haelyra 423edc1d46 Merge PR #3441: initialize OpenCode home hooks once 2026-10-10 17:36:05 -04:00
haelyra b3c3b77561 Merge PR #3440: observe active worktree changes 2026-10-10 17:35:52 -04:00
haelyra 7753a55d08 Merge PR #3416: route hook state through Claude profiles
Preserve the explicit shared ~/.claude project root already shipped on main. Canonicalize macOS temporary workflow fixture paths.
2026-10-10 17:35:45 -04:00
haelyra df50d56146 Merge PR #3283: serialize session alias mutations 2026-10-10 17:34:44 -04:00
haelyra aac9b3d34b fix: preserve activity errors, asset bytes and runner summaries
Treat non-2xx activity responses as feed errors, preserve non-Markdown Copilot agent assets, and apply the reviewed reference escape parity correction with regenerated bindings. Allow the test runner to drain piped output on its existing success or failure exit status. Validate installed workflows and bounded real Node20/24 pipe regressions.
2026-10-09 19:33:37 -04:00
haelyra 5981dd7092 fix: complete reviewed integration workflows and safety checks 2026-10-09 18:54:39 -04:00
haelyra b6e2cfe5e4 merge: preserve tested installer extraction 3187 and Copilot ownership fixture 2026-10-09 17:05:03 -04:00
haelyra d312d6f35c merge: preserve project and user Codex configuration source 3253 2026-10-09 17:02:47 -04:00
haelyra eed806bf4a fix: restore unskipped installer refactor validation
Follow up PR #3187 at 38b8c07f while preserving the original contribution history and all current-main helper bodies. Remove both CI safety-suite exclusions, clean stale imports and the warning glyph, retain shipped test/coverage entrypoints, and keep unknown test totals honest. The tree matches the fully tested 6246-pass/325-file tree; disposable Claude/OpenCode lifecycle passes.
2026-10-09 16:32:47 -04:00
haelyra 67c89375c3 merge: preserve serialized store source 3252 with portable cache fixtures 2026-10-09 16:28:34 -04:00
haelyra 195301cb04 merge: preserve tested optional dependency carry-forward 3119 2026-10-09 16:21:29 -04:00
haelyra cc288b6e28 merge: reconcile tested OpenCode home carry-forward with Copilot transforms 2026-10-09 16:20:04 -04:00
haelyra 34ba911ad3 merge: preserve tested Python audit source 3007 2026-10-09 16:11:22 -04:00
haelyra 83cd2ad91e merge: preserve tested commit-review source 2974 2026-10-09 16:10:04 -04:00
haelyra 2ad3bdbef4 merge: preserve tested Copilot install sources 2960 and 2963 2026-10-09 16:09:01 -04:00
haelyra c4f419bea0 merge: refresh reviewed stewardship source 3280 on current main 2026-10-09 16:02:58 -04:00
montjeffrey c6b2c55b87 fix(hooks): never run .sh hooks through the WSL bash launcher on Windows
plugin-hook-bootstrap (shell mode) and observe-runner probed a bare
`bash.exe`. On Windows that resolves to the first match on PATH, and
%SystemRoot%\System32 normally sits ahead of Git's bin directory, so the
pick was System32\bash.exe: the WSL launcher. The existing guard (require
a clean probe exit) only catches it when no distro is installed. With one
installed, the probe passes inside Linux, then the hook script is handed
over by a Windows path (C:\...) or a Git Bash path (/c/...), neither of
which exists in WSL. The hook exits 127 instead of running, and
observe-runner's continuous-learning observation fails on every call.

Resolve bash candidates on Windows to absolute paths from PATH, skipping
bash.exe in System32, SysWOW64, Sysnative, and the WindowsApps alias
directory, so a native bash later on PATH (Git's) is used. With none
available, the existing "no bash binary found" skip applies. An explicit
BASH override still wins, and other platforms keep bare names.

The shared resolver lives in scripts/lib/windows-bash.js with a
platform-independent test. A Windows integration test puts System32 ahead
of Git's bash and requires the .sh hook to actually run. Upstream's
bootstrap fails that scenario with exit 127 ("/bin/bash: C:Users...hook.sh:
No such file or directory"); this one prints the hook output.
2026-10-09 15:56:14 -04:00
haelyra 131c6186c3 feat: integrate native Copilot skill and agent distribution
Preserve contributor histories for PR #2960 and #2963. Resolve current-main conflicts without dropping OpenCode behavior. Reject traversal source paths, keep volatile inventory counts observational, and apply the shared ownership guard during every adapter repair while retaining adapter-derived roots. RED ownership and traversal regressions now pass, 73 lifecycle tests pass, and native Copilot observes 288 enabled project skills. Disposable install, missing-file repair, and uninstall preserve user-authored agents.
2026-10-09 15:53:38 -04:00
Danteandhaelyra c29a724bcd fix: declare optional cross-target install dependencies
Carry forward the final scoped delta of PR #3119 at 60e82f95. Keep required dependency closure and select only modules reachable from successful requests; refresh the unchanged 293-skill registry binding.
2026-10-09 15:43:31 -04:00
Yusuf Efeandhaelyra 0f34fdcc14 fix: resolve installed OpenCode skill paths consistently
Carry forward PR #3115 ef475c79 and 780dfb78 onto current main. Preserve the newer hook-consent transforms during install and repair. Main already includes the source import fix from #3167.
2026-10-09 15:40:12 -04:00
Yann Roberto 39796acf2f perf(state-store): reuse unchanged read snapshots
Keep the operation lock while validating bigint file identity and reuse
only snapshots produced by successful trusted static SELECTs. Avoid
reloading and exporting unchanged databases on repeated public reads.

Retain conservative comparison for generic SQL, including RETURNING and
PRAGMA writes, and invalidate reuse after transactions, exports or errors.
Cover cache invalidation, cross-process visibility, Windows device IDs,
reentrant partial writes, lock contention and independent result objects.

Validate 188 focused tests per environment on WSL Node 22.22.3 and native
Windows Node 22.15.0/24.16.0, plus 38 related WSL tests. Paired warm-read
benchmarks show 7.6-18.1x point-query speedup on 160 KiB/1.28 MiB databases.
2026-10-09 17:04:56 +08:00
Yann Roberto a6ce6fbbdb fix(state-store): tolerate missing Windows lock device IDs
Handle Windows Node path stats that report dev=0 for the same file whose
open descriptor reports a volume serial. Keep bigint inode checks strict,
retain device comparisons whenever both are known, and leave POSIX strict.

Cover zero-device identity cases, high inode precision, replacement and
file-type safeguards. Verify 164 focused tests each on native Windows
Node 22.15.0 and 24.16.0, plus WSL Ubuntu Node 22.22.3.
2026-10-09 16:46:19 +08:00
Yann Roberto f76c469fa7 fix(state-store): persist writes from prepared result queries
Compare the completed snapshot after get/all queries so RETURNING and
prepared PRAGMA writes survive reloads and reopening. Export only after
the outer operation or transaction succeeds; unchanged read snapshots
still avoid disk writes. This adds one export/byte comparison per read
snapshot without relying on SQL parsing or private sql.js APIs.

Add 18 regression cases covering multi-row INSERT/UPDATE/DELETE RETURNING,
standalone and transactional get/all, no-row PRAGMA writes, and rollback.
The unfixed adapter fails 16 of these cases. Strengthen read-only checks.

Validation: 148 focused tests pass on WSL Node 22 and Windows Node 24;
the general state-store suite passes 20/20 on WSL and 19/20 on Windows,
where the existing file-symlink fixture is denied by Windows permissions.
Scoped adapter coverage is 90.13% lines, 82.73% branches, 100% functions.
ESLint, Unicode safety, and git diff --check pass.
2026-10-09 16:28:30 +08:00
Eneko Ruiz 684c971173 fix(hooks): resolve session IDs from hook payloads 2026-10-08 23:46:56 +02:00
Varun GoreandGitHub 38b8c07f26 Merge branch 'affaan-m:main' into main 2026-10-08 19:36:33 +05:30
serhattayaz-ai bb95734f4e fix(install): keep namespace stripping when link rewriting is skipped 2026-10-08 16:19:57 +03:00
serhattayaz-ai 27d58e589a fix(install): strip ecc: plugin namespace from manual Claude installs
The ecc@ecc plugin namespaces agents, commands and skills as `ecc:<name>`.
A manual install (install-apply --target claude|claude-project) places the
same files at bare names under ~/.claude, so plugin-prefixed references in
copied markdown point at agents and commands that do not exist in that
layout (e.g. subagent_type "ecc:planner", frontmatter agent: ecc:...).

- Add plugin-namespace.js with stripPluginNamespace(), which removes the
  `ecc:` prefix before an identifier and leaves `ecc@ecc`, URLs and words
  ending in "ecc" alone.
- Apply it to markdown copy operations when the target is claude or
  claude-project. Non-markdown files and other targets are unchanged.
- Reword the agents rule so it describes both install modes instead of
  stating that agents only ship with the plugin.
- Cover the transform with tests/lib/install-plugin-namespace.test.js.
2026-10-08 16:10:35 +03:00
YogurDungeon b4943a5e4b fix: record skill runs under OpenCode and report unmeasured skills honestly
Under OpenCode the skill-health dashboard had no writer and no honest
fallback, so it reported every discovered skill as healthy (#2463).

Root cause: `post:skill:track` is only wired for Claude Code, where
`posttooluse-dispatcher.js` fans the event out to `skill-run-tracker.js`.
The OpenCode plugin re-implements the harness events instead of reusing that
dispatcher, so nothing ever wrote `skill-runs.jsonl` — and the tracker's
matcher only accepted the exact Claude Code tool name `Skill`, while OpenCode
calls the tool `skill`, so even wiring it would have dropped every event.
Commands that locate ECC through the inlined resolver in
`scripts/lib/resolve-ecc-root.js` also fell back to `~/.claude`, which does
not contain ECC, so they could not find their scripts.

Changes:

- `.opencode/plugins/ecc-hooks.ts`: dispatch `post:skill:track` from
  `tool.execute.after`. The tracker module is imported lazily and behind
  try/catch, matching the existing `changed-files-store` pattern: this file is
  OpenCode's startup entry point, so a static import failure would crash the
  session before any hook runs (#2530). The module is reused rather than
  reimplemented, keeping its identifier validation, length bounds and
  "never persist prompt text" guarantees.
- `scripts/hooks/skill-run-tracker.js`: match the tool name case-insensitively
  so `Skill` and `skill` are both accepted.
- `scripts/lib/skill-evolution/health.js`: split the summary into
  measured/healthy/declining/unmeasured instead of deriving `healthy = total -
  declining`, which turned "no telemetry" into "everything is fine" for every
  skill.
- `scripts/lib/skill-evolution/dashboard.js`: show the breakdown and warn
  explicitly when skills have no recorded runs, since absence of telemetry is
  not a health signal.

Under OpenCode the resolver also needs `CLAUDE_PLUGIN_ROOT`, which only the
plugin can supply: `shell.env` exports it when a root is found, without
replacing a root the user set or one an earlier plugin already put in
`output.env`.

Root discovery is per capability and probes required runtime files — never
optional content. Probing for `skills/continuous-learning-v2` (the
`workflow-quality` module) rejected supported modular installs that ship the
plugin and tracker without that optional module, disabling telemetry and the
root export for exactly those users.

Also fixes an incidental bug: the compiled plugin bundle is ESM, where
`__dirname` is undefined, so the ECC version lookup silently fell back to its
default. The module directory is now derived from `import.meta.url`.

Tests: `tests/opencode-plugin-hooks.test.js` covers the telemetry dispatch
(skill tool recorded, other tools ignored, minimal profile respected), a
modular install without the optional skills module, the root export and both
override paths; `tests/hooks/skill-run-tracker.test.js` covers the
case-insensitive matcher; `tests/lib/skill-evolution.test.js` and
`tests/lib/skill-dashboard.test.js` cover the unmeasured bucket, the warning
and the aged-out-coverage wording.

Refs #2463, #2530
2026-10-07 19:45:21 -05:00
Huanyi Xie f7d7532d65 fix(proximity): decode quoted paths with precise line ranges 2026-10-06 21:05:58 +03:00
Huanyi Xie 52cc44f40a fix(proximity): isolate diff headers and preserve partial probes 2026-10-06 20:12:07 +03:00
Huanyi Xie 3989e50ab3 fix(proximity): retain all tracked working-set paths 2026-10-06 20:08:48 +03:00
Huanyi Xie 990e45e177 fix(opencode): avoid duplicate home plugin initialization 2026-10-06 19:41:18 +03:00
Huanyi Xie 72d738de37 fix(proximity): observe uncommitted worktree changes 2026-10-06 19:39:22 +03:00
Yann Roberto d69eaecf25 fix(state-store): keep cleanup diagnostics off caller errors 2026-10-06 00:36:11 +08:00
Yann Roberto 8be6a6f292 chore: sync state store branch with main 2026-10-05 00:15:25 +08:00
Yann Roberto d38b079115 chore: sync session alias branch with main 2026-10-05 00:15:20 +08:00
basil-k-aji-dev cd85014b9e fix(plan-canvas): route session state through CLAUDE_CONFIG_DIR
The Plan Canvas library wrote ~/.claude/plan-canvas while the SessionStart
and Stop hooks read CLAUDE_CONFIG_DIR/plan-canvas. Under a second profile
SessionStart missed open reviews and Stop let a turn end with feedback
still queued.

Expand a leading ~ in CLAUDE_CONFIG_DIR the way scripts/lib/agent-data-home.js
does, so a profile written as ~/.claude-work resolves to one directory rather
than two.

Add hook-level coverage that spawns each hook with a distinct
CLAUDE_CONFIG_DIR and no ECC_* override, plus a producer-to-consumer round
trip. Eight of the nine cases fail against the previous revision.
2026-10-03 20:20:40 +05:30
basil-k-aji-dev 00d73fbae2 fix(hooks): honor CLAUDE_CONFIG_DIR instead of writing to ~/.claude
Claude Code points every profile-local path at CLAUDE_CONFIG_DIR when it is
set, but ECC hooks kept reading and writing ~/.claude. A session launched
under a second profile left its bash log, cost tracker, metrics, session data
and skill runs in the default profile, where the other one reads them back.

Two groups, as reported:

- getDefaultClaudeAgentDataHome() in scripts/lib/agent-data-home.js now
  follows the variable, which covers every hook reaching ~/.claude through
  resolveAgentDataHome(). ECC_AGENT_DATA_HOME still wins, so the documented
  workaround keeps working.
- plan-canvas-pending, plan-canvas-sessions, mcp-health-check and
  post-bash-command-log hard-coded os.homedir()/.claude and now resolve the
  same way, matching scripts/hooks/ecc-statusline.js:68.

A blank value is ignored rather than resolved, since path.resolve('  ')
returns the process cwd and would scatter profile data through whatever
directory the session started in.

Fixes #3266
2026-10-03 12:34:14 +05:30
Affaan MustafaandGitHub c05b2d6614 chore: retire the Everything Claude Code name, ECC only (#3330)
* chore: retire the Everything Claude Code name, ECC only

Replace the expanded product name and the everything-claude-code slug
with ECC across READMEs, translated docs, harness folders, skills,
commands, scripts and examples. Repo URLs now point at affaan-m/ECC.

Rename repo-internal artifacts to ecc forms (ecc-conventions skill,
ecc-guardrails, ecc-research-playbook, ecc-team-config, ecc-instincts
with ecc-* ids) and update .claude/ecc-tools.json.

Legacy install ids, plugin dirs, package names and MCP prefixes stay
where existing installs resolve against them. The codex global-state
check and harness-audit repo detection accept the new name first and
the legacy one as a fallback. The Discord bot prefers ~/GitHub/ECC and
falls back to the nested legacy checkout path.

Refresh the skill-triggers registryDigest for the changed skill text.

* fix(ecc-tools): drop managed paths to the removed Claude repo skill

.claude/skills/<repo-skill>/SKILL.md was deleted in #2770 but stayed listed in
ecc-tools.json and the team config. Remove those entries and point the Claude
Code adapter at the existing .agents/skills/ecc-conventions/SKILL.md.
2026-10-01 17:50:41 -05:00
Yann Roberto 184c657788 fix(sessions): preserve committed results on lock cleanup errors 2026-10-01 14:59:29 +08:00
Yann Roberto b1ba495997 fix(sessions): serialize alias read-modify-write operations 2026-10-01 13:27:55 +08:00
haelyra 7c03203dd8 Merge remote-tracking branch 'refs/remotes/pr/3267' into maint/stewardship-batch-2026-09-30 2026-09-30 13:21:01 -04:00
haelyra c965a61da5 Merge remote-tracking branch 'refs/remotes/pr/2655' into maint/stewardship-batch-2026-09-30
# Conflicts:
#	.claude-plugin/marketplace.json
#	.claude-plugin/plugin.json
#	AGENTS.md
#	README.md
#	README.zh-CN.md
#	docs/de-DE/README.md
#	docs/es/README.md
#	docs/ja-JP/README.md
#	docs/ko-KR/README.md
#	docs/pt-BR/README.md
#	docs/ru/README.md
#	docs/th/README.md
#	docs/tr/AGENTS.md
#	docs/tr/README.md
#	docs/uk-UA/README.md
#	docs/ur/README.md
#	docs/vi-VN/README.md
#	docs/zh-CN/AGENTS.md
#	docs/zh-CN/README.md
#	docs/zh-TW/README.md
#	scripts/lib/install-manifests.js
2026-09-30 13:20:41 -04:00
Yann Roberto 3768c03653 fix(state-store): preserve permission errors after lock retries 2026-10-01 01:03:41 +08:00
Yann Roberto 94cd7db7c3 fix(state-store): retry Windows contention and repair fixtures 2026-10-01 00:25:22 +08:00
drakeo338andClaude Sonnet 5.5 334b7847bd fix(hooks): keep ~/.claude eligible as project sharing root with CLAUDE_CONFIG_DIR
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-09-30 12:43:02 +00:00