diff --git a/CHANGELOG.md b/CHANGELOG.md index 5320979..410f7e0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -61,6 +61,7 @@ Format follows [Keep a Changelog](https://keepachangelog.com/) and this project - Known limit: `cc x web` on a project in `dev` keeps the higgsfield connectors denied (`deniedMcpServers` is a union); `profile.sh set web` in the project lifts them from the next session. - Measured headless on 2026-11-02: dev = `pack-gstack-dev`, 41 tools, 0 higgsfield; web = the six web packs, 199 tools, both connectors `connected` and 158 higgsfield tools listed in init (the stderr line "blocked by enterprise policy: claude.ai higgsfield, claude.ai Higgsfield AI" appeared on the deny profiles dev, qa, seo and minimal: that is `deniedMcpServers` working); qa = `pack-gstack-browser pack-web-validate`; seo = qa + `pack-gstack-dev pack-seo`; qa and seo 41 tools, 0 higgsfield; reload canary in one flagless session (id `ee65507c-a958-411b-9580-8aca8105e326`): `/seo` unavailable on minimal, `profile.sh enable seo`, `/reload-plugins` -> "Reloaded: 3 plugins · 2 skills · 32 agents · 7 hooks", then `/seo` and `/pack-seo:seo` both load the SEO skill. `profile.sh current --plain` median 30 ms (target 50). - Listing budget with the packs: measured headless on 2026-11-02 with `--model haiku` (name-only skills, entries 124 on full, 90 on dev): full default 58, 40000 11, 50000 0, 60000 0; dev default 9, 40000 and above 0. Set `SLASH_COMMAND_TOOL_CHAR_BUDGET=50000` in `settings.json` `env`, the smallest tested value with 0 name-only on full. Cost, estimated: full (48.5k - 30.3k bytes) / 4, about 4.5k tokens; dev 30.0k to 36.8k bytes, about 1.7k tokens. `env` is global, so every profile pays. Descriptions are no longer truncated at 50000 (natural size 48.5k). The default budget's absolute value was not read; it may depend on the model's context window. +- gitflow pre-commit (`lib/gitflow.sh`, generated `githooks/pre-commit` and per-repo `.githooks/pre-commit`) exempts on `main`/`develop` only staged paths under `.claude/memory/`, `.claude/tasks/`, `.claude/audits/`, `.claude/deploy/` and `.githooks/`, was all of `.claude/**`. A commit touching `.claude/rules/`, `.claude/settings.json`, agents or skills on a protected base is now blocked: branch first. Staged paths are listed with `--no-renames`, so a `git mv` from a blocked path into the allowlist is blocked too. Per-repo hooks pick it up at the next session start, the global ones at `make link`. Tests: `lib/gitflow-test.sh` T21d-T21h. ### Removed - `rules/default-language.md`: its content is `lib/architecture-defaults.md` § Default language. @@ -77,6 +78,10 @@ Format follows [Keep a Changelog](https://keepachangelog.com/) and this project - An invalid `gitflow.autopush` value (not a boolean, or a config read that fails) no longer pushes. The post-commit / post-merge hooks and every push site of `lib/gitflow.sh` (`start`, `finish`, the `origin/` cleanup of `delete`) read it as auto and pushed; they now push nothing and say why. Each hook run prints `gitflow post-commit: gitflow.autopush unreadable (git rc ) — NOT pushed, treated as manual push mode; fix the value by hand` (post-merge likewise), and the lib passes through the `push-mode` verb's line, `gitflow.sh push-mode: gitflow.autopush='' is not a boolean (git rc )`. A repo with its own committed `.githooks/` (onboarded projects) keeps running its old hooks, which still push on an invalid value, until a session start runs `reconcile-hooks` and rewrites them; commit that refresh so other clones get it. Tests: `lib/gitflow-test.sh` T18q block. - `/guardrails` residuals. The live probe fails closed in more cases: every followed same-host redirect is charged to the request budget, and a budget that runs out mid-redirect reads ERROR; an anon-read or cross-user answer that is not a 200 or a refusal, or a 200 whose body is empty, over 1 MB or not JSON, reads SKIPPED instead of CLOSED; a rate-limit burst cut short by the budget or the transport reads SKIPPED; the source-map probe tries every candidate map of a script instead of stopping at the first it cannot confirm, and a `data:` map is OPEN whatever its encoding; the fields probe no longer flags metadata keys (`token_type`, `has_password`, `next_page_token`). The plan's Supabase `url` must be an http(s) url when tables or cross-user paths are set, `supabase.tables` must be a list of strings, and the `--authorized` refusal names both hosts. Scanner and probe text output strip control characters from file names and remote strings. Static rules lose false positives (hydrated state read per export chunk, webpack dev configs, `data-*` names with a UI suffix such as `-toggle` or `-strength`, GraphQL `_bool_exp` and capitalised types under `$where`) and gain detections: Go backtick SQL in `fmt.Sprintf`, `rf` / `fr` and triple-quoted Python f-strings, `sql.raw` / `db.raw` / `trx.raw`, an empty `.select()` on a users table, a hidden input spanning lines, a Rust `{}` argument to a DB shell tool, a large public `.map` whose head holds `"sources"`. Tests: `lib/tests/guardrails-scan.test.sh`, `lib/tests/guardrails-probe.test.sh`. - `lib/tests/mods.test.sh` judges `claude plugin validate` by the exit code of `--strict` instead of scraping its output: per-file warnings exit 1 and fail the mod, and the advisory plugin-directory section that CLI 2.1.306 prints (`ICON_MISSING`, not blocking) no longer counts as a failure, as the old whole-output `warning` grep did. A failure prints the `✘` / `error:` lines and the `--strict` command to rerun. A positive control writes two scratch manifests in a temp dir and checks that `--strict` passes the clean one and fails the one with warnings, so the gate cannot pass vacuously. +- `settings.json` denies `Bash(rtk read * .env*)` and `Bash(*/rtk read * .env*)`: the `rtk read` twin of the flag-form `cat * .env*` deny was missing, so an `rtk read` with a flag before a root `.env` passed. push-guard T63 pins both. +- `hooks/session-start.sh` bounds its `memory.sh check` with `timeout 2` when `timeout` is installed: a hung check no longer stalls every session start. +- `lib/memory.sh` reads a path shaped like an awk assignment (`x=1.md`, `a=b`) as a file: `add --body-file`, `check` and `upgrade` prefix it with `./`, where awk took it for a `var=value` operand and read stdin. Tests: `lib/tests/memory.test.sh` T19, T19b, T19c. +- Hook-running test suites source `lib/tests/claude-stub.sh`: a logging `claude` stub goes first on PATH and the suite exits if it is not the one resolved, so a hook run can no longer start a real session that re-runs the hook (fork bomb). Suite `lib/tests/claude-stub.test.sh`. ## [2.0.0] — 2026-10-06