Skip to content

v0.4.0

Latest

Choose a tag to compare

@github-actions github-actions released this 13 Nov 01:12
699f8fd

Everything since 0.3.0. Update if you run 0.3.0 or earlier. In those versions a check followed later by || counted as passing, so a failing test run could open the done-gate. On Windows, edits that skipped or deleted tests went through unasked. Files a shell command never wrote, and files outside the project, could hold the done-gate with nothing to run. The hook entries canny init writes have not changed since 0.3.0, so updating ~/.canny/src is enough. Coming from 0.2.x, run canny init again in each guarded project to add the SessionStart hook.

Added

  • require in .canny.json: regexes that each have to match a passing check after the last code edit before a Stop is allowed. Until now any one check opened the done-gate, so eslint passing after a logic change let "done" through with the tests never run. The block reason, the SessionStart brief, and canny status name the checks still needed, with control characters removed, since a cloned repository can write the patterns. The field only asks for more, so like strict it takes effect without canny trust; a pattern can only be satisfied by a command that already counts as a check.

Fixed

  • A file outside the project no longer holds the done-gate. An edit to ~/.zshrc, a key written to the home directory, or a copy into another checkout used to count as a code change that no project check could clear, so a session doing only configuration work was blocked with nothing to run. The project is the nearest directory at or above the session's that holds .git, so an edit elsewhere in the repository still counts when the agent works in a subdirectory. A leading ~ in a shell path is read as the home directory.
  • A test file run directly counts as a check: python tests.py, python3 tests/test_api.py, node test.js, ruby test/user_test.rb. The file name has to say it is a test (test, tests, test_*, *_test, *_tests, *.test, *.spec), so python manage.py still checks nothing.
  • The block reason says a redirect into a file (> out.log 2>&1) does not hide a check's exit status, next to the forms that do.
  • Paths with Windows separators are read like any other. The patterns for test files, ignored directories, and env files only accepted /, while Claude Code on Windows sends C:\… and path.relative answers with \ there. So adding test.skip( to tests\helper.js or deleting it went through without a question, an edit under docs\ or node_modules\ blocked the Stop, and a key written to a git-ignored config\.env was denied. The ledger now records paths with / on every system, so an ignore pattern such as ^generated/ matches on Windows too.
  • On Windows a Git Bash path (/c/Users/…) is read as C:\Users\…. It used to resolve to C:\c\Users\…, so the test-removal check read a file that does not exist and let the write through.
  • A check followed later in the same command by || no longer counts as passing: pnpm test && echo ok || true exits 0 when the tests fail, because the || rescues every command before it. Only an || directly after the check was caught before.
  • The ledger no longer records files a shell command never writes. Commands inside quotes (ssh host "cp a $B/x", grep -E "cp |mv " f) were read as shell, a variable such as $DST/a.ts was recorded as a file, a substitution such as bak-$(date +%Y%m%d) was split into two names, and a leading cd was ignored, so relative paths landed in the wrong directory. Each of these could hold the done-gate on a file nothing had changed.
  • python3 -m unittest counts as a check, like python -m unittest.
  • bench/run.mjs on Windows runs each task's npm test through a shell. npm is npm.cmd there and cannot be started directly, so every task read as failed whatever the agent did.

Full changelog: v0.3.0...v0.4.0