Repository navigation
Releases
v0.7.4 — trusted verification profiles
Asha 0.7.4 — trusted verification profiles
Fixes the policy-model gap where a project that deliberately gates on neither
ruff nor mypy was permanently BLOCKED: the S3 matrix is repository-agnostic,
so a missing executable became a skipped required check, and a skip is never
a pass.
A verification profile now states the authoritative checks per service, in
an operator-signed, repository-bound, digest-bound file:
{
"schema": 1,
"id": "detailist",
"repository": {"remotes": ["github.com/void-detailist/detailist"],
"ci_workflows": [".github/workflows/ci_compiler.yml"]},
"services": {
"compiler": {
"root": "compiler", "timeout_s": 1200,
"checks": {"pytest": ["-m", "pytest", "tests", "-q"]},
"not_configured": {"ruff": "<provenance>", "mypy": "<provenance>"}
}
},
"provenance": {"declared_by": "operator"}
}Selected with ASHA_VERIFICATION_PROFILE=/path/to/profile.json — never from a
task-spec field, so a worker cannot widen or narrow its own matrix. Loading
fails closed on an invalid schema, an origin the profile does not name, or an
undeclared service; the file is hashed before the first check and re-read
before sealing, so a candidate that edits it cannot change the run it is in.
NOT_CONFIGURED is a distinct verdict: reported, excluded from the required
set, never counted as a pass, and never inferred from a missing executable. An
inventory of nothing but NOT_CONFIGURED entries is BLOCKED — nothing was
verified. Without a profile, behaviour is byte-for-byte the old matrix
(ruff + pytest + mypy, skip → BLOCKED).
Shipping authority is unchanged: worker evidence still seals
authorized_to_ship: false; a profile changes which checks are required,
never who authorizes shipping.
Included
asha/verification_profile.py— schema, trust rules, digest, statementcheck_runner— profile-planned per-service commands, explicit
NOT_CONFIGUREDentries, one resolution point for DAG, single-worker/MCP and
tip-verification pathsvalidation—not_configuredexcluded from the required set; all-unverified
inventories stayBLOCKEDworker_execution— snapshot before checks,verify_unchangedbefore the
diff,verification_profile(id, digest, source, remotes, CI sources) in the
sealed evidencedocs/verification-profiles.md— schema, verdicts, fail-closed rules- 22 regression tests, including "worker spec cannot weaken the matrix",
"profile cannot be replaced after snapshot" and DAG/single-worker parity
Verification
- CI
verify(3.10/3.11/3.12: ruff + mypy + pytest) — pass - CI
fail-closed governance gate— pass - Local full suite: 34 failed / 1490 passed / 3 skipped — the v0.7.3 baseline's
exact pre-existing failure set (no new failures; +22 new tests) - Wheel
asha-0.7.4-py3-none-any.whl
sha256 6aba37221ff29608c6a6a67a7720b3aa049f951be483a3876992c58e145e872e
(359634 bytes, 84 members, RECORD verified 83/83, contents = exactly the four
changed modules + the new one vs 0.7.3)
Full changelog: v0.7.3...v0.7.4
v0.7.3 — output contract (no-op runs cannot be DONE)
Why
A passing verification suite proves the tree still works; it never proves the
worker did its job. Observed in a real governed run (delegated review task):
the worker changed nothing, the workspace stayed at the baseline tree, every
pre-existing test passed, and Asha sealed the run as DONE.
What changed
New asha/governance/output_contract.py turns the task's declared expectation
into a record that acceptance must satisfy before a run may be DONE:
| declaration | requirement |
|---|---|
writes: [...] (or output_kind: changes) |
at least one declared write changed; temporary/unrelated files do not count |
required_artifacts: [...] (or output_kind: artifact) |
each path exists, is non-empty, and was created/modified during this run |
no_change_reason: "..." (or output_kind: no_change) |
nothing changed and the reason says why that is correct |
nothing declared (uncontracted) |
legacy task: it must still change something, so silence is never success |
Enforcement lives in collect_worker_evidence — the single collection path the
DAG and the single-worker/MCP routes share — so both refuse identically.
A refused run still seals its honest record (writes_observed, the contract
record, diff, checks), but:
state: FAILED,reason: output_contract_not_satisfied:<why>validation_status: FAIL,verification_status: OUTPUT_CONTRACT_NOT_SATISFIEDready_to_push: false; no fabricated success anywhere
An unproven acceptance keeps its own, more specific refusal (acceptance_failed).
asha_dispatch_task accepts the same three fields, so one declaration
vocabulary covers dispatch and run --spec.
Tests
tests/test_output_contract.py — 16 tests covering the contract rules and the
required scenarios: real change, no change with green tests, unrelated temp
file, untracked source file, deletion, report written, report printed but not
written, empty report, explicit no-op, missing/empty artifact, non-zero exit,
and DAG/single-worker parity.
Fixtures that rely on an intentionally unchanged tree now declare it, and
test_k61_codegraph's slice bound moves 114000 → 116000 by the measured
114572 (stub-dominated, target body unchanged), with the reason recorded.
Measured locally: 1468 passed, 33 failed, 3 skipped vs baseline
1452 passed, 33 failed, 3 skipped at abaa010 — same failure set, +16 tests.
Version: 0.7.3.
v0.7.2 — the scoped check path records its environment
What this fixes
An independent audit of v0.7.0 (never using a client repository) reproduced two
failures. One was a genuine Asha defect, one a git-lifecycle robustness gap.
v0.7.1 shipped the first pass; installing that wheel in a fresh runtime and
re-running the failure case exposed a hole in it, fixed here.
1. comparison_inconclusive:baseline_failures_unparsed — fixed properly
A governed run's baseline check matrix ran under Asha's own interpreter
because the target project had no service-local environment, so pytest aborted
in collection on a missing dependency. Asha correctly refused to pass, but
every cause collapsed into one opaque unparsed detail.
asha.governance.check_diagnosisclassifies each failed check from its own
output:environment_unresolved,missing_dependency,tool_unavailable,
collection_error,test_failures,timeout,crashed,unknown. A
stdlib or repository-local module is a collection error, not a missing
dependency.- Every check entry records
interpreter,hermetic,service_root,
failure_mode,failure_module— on both check paths.run_scoped
builds its own entries next to_run_group, and v0.7.1 decorated only the
latter, so governed runs reported the gap with null identity; both now end in
one_annotate(). - The comparison reports
baseline_missing_dependency(withdiagnosisand an
actionablehintnaming the module, the interpreter and the fix) and refuses
to compute a delta across two different interpreters
(INTERPRETER_MISMATCH).performedstaysfalse. - Acceptance exits
2(interrupted / collection error) and3(internal
error) areinconclusive, notfailed: the runner produced no verdict.
4/5unchanged;1still means the tests ran and failed.
2. fatal: Unable to create '.git/index.lock'
git add -A failed instantly when another git process — usually the worker's
own — held the index, aborting the run before acceptance was evaluated.
git add now waits up to INDEX_LOCK_WAIT_S (3s) for the lock and retries,
then refuses with the lock path and safe recovery instructions. No lock is
ever deleted: Asha cannot prove the owning process is gone. The lock path is
read from the filesystem, so no git subprocess is added to the evidence budget.
Fail-closed rules are unchanged
DONE still requires a demonstrated pass; an inconclusive comparison writes no
seal; every non-passed acceptance outcome still blocks the run.
Verification
- Fresh 0.7.2 runtime, two synthetic repos with their own
.venv:- green repo, real change + passing acceptance →
DONE,COMPARED/
NO_FAILURES, evidence sealed; - repo whose base revision imports an uninstallable module →
FAILED,
comparison_inconclusive:baseline_missing_dependency, hint naming the
module and interpreter, no seal.
- green repo, real change + passing acceptance →
- MCP stdio handshake on the installed wheel:
asha-orchestrator 0.7.2, 14
tools; worker policy active,clean-code4.0.0 preloaded with a matching
SHA-256, non-coding opt-out intact. - CI on the exact release commit:
fail-closed governance gatepass,verify
(full Linux suite, ruff, mypy) pass — 1 failed, 1484 passed, 3 skipped on the
intermediate head, where the only failure was the frozen-trio anchor that the
final commit of this branch advances. - Local Windows suite vs the v0.7.0 baseline: identical failure sets
(33 pre-existing Windows environment failures), zero new failures. - New regression tests:
test_environment_diagnosis.py(including the scoped
path's identity fields),test_index_lock_guard.py,test_mcp_dag_parity.py,
and the acceptance no-verdict cases.
Wheel
asha-0.7.2-py3-none-any.whl
SHA-256 e31562db55e3d69245cea143ace4034494ebae5778d042c4211cfe274c1cc4fe
Docs: docs/ENVIRONMENT-DIAGNOSIS.md.
v0.7.1 — environment diagnosis and a lock guard for governed runs
What this fixes
An independent audit of v0.7.0 reproduced two failures and classified them:
one genuine Asha defect, one a robustness gap in the git lifecycle.
1. comparison_inconclusive:baseline_failures_unparsed
A governed run's baseline check matrix ran under Asha's own interpreter
because the target project had no service-local environment, so pytest aborted
in collection on a missing dependency. Asha correctly refused to pass — but
every cause collapsed into the same opaque unparsed detail, so an operator
could not tell an environment gap from a worker who broke the suite.
Now:
asha.governance.check_diagnosisclassifies each failed check from its own
output:environment_unresolved,missing_dependency,tool_unavailable,
collection_error,test_failures,timeout,crashed,unknown. A
stdlib or repository-local module is a collection error, not a missing
dependency.- Every check entry records
interpreter,hermetic,service_root,
failure_mode,failure_module. - The comparison reports
baseline_missing_dependency(withdiagnosisand an
actionablehint) instead of a bareunparsed, and refuses to compute a
delta across two different interpreters (INTERPRETER_MISMATCH).
performedstaysfalsein both cases. - Acceptance exits
2(interrupted / collection error) and3(internal
error) areinconclusive, notfailed: the runner produced no verdict.
4/5unchanged;1still means the tests ran and failed.
2. fatal: Unable to create '.git/index.lock'
git add -A failed instantly when another git process — usually the worker's
own — held the index, aborting the run before acceptance was evaluated.
git add now waits up to INDEX_LOCK_WAIT_S (3s) for the lock and retries,
then refuses with the lock path and safe recovery instructions. No lock is
ever deleted: Asha cannot prove the owning process is gone, and removing a
live lock corrupts the index. The lock path is read from the filesystem, so no
git subprocess is added to the evidence budget.
Fail-closed rules are unchanged
DONE still requires a demonstrated pass; an inconclusive comparison still
writes no seal; every non-passed acceptance outcome still blocks the run.
Verification
- Full suite on Windows (this machine), same revision: 33 failed, 1451
passed, 3 skipped vs the v0.7.0 baseline 33 failed, 1417 passed, 3
skipped — identical failure sets (pre-existing Windows environment
failures: worktree seal paths, CRLF, restart durability), zero new
failures, 34 new tests. - CI on the exact release commit:
fail-closed governance gatepass,verify
(full Linux suite, ruff, mypy) pass. - New regression tests:
test_environment_diagnosis.py,
test_index_lock_guard.py,test_mcp_dag_parity.py, plus the acceptance
no-verdict cases intest_acceptance_gate.py.
Wheel
asha-0.7.1-py3-none-any.whl
SHA-256 5f3a722de0c00522745fad56f9c9e0a22574d81c1883cd4b473a2aa384b8918f
Docs: docs/ENVIRONMENT-DIAGNOSIS.md.
v0.7.0 — audited acceptance and a default coding Skill for workers
Headline
asha run --spec can no longer seal a worker whose acceptance never ran, and a
coding worker now receives the mandated clean-code Skill because Asha put it
there — not because the Spec author remembered a flag.
Fixed
- Acceptance was recorded as
not_executedfor every governed worker. The
DAG coordinator bound its execution hook todefault_execute, which discards
the runner's audit record, sobuild_acceptancealways saw
verify_ran=False. Any Spec withverify_commandfailedacceptance_failed
regardless of the command's real result. The hook is now
execute_with_audit, and the audit reaches evidence collection. Injected
2-tuple hooks keep working (they simply carry no audit). - A non-passing acceptance could still be sealed. Acceptance was consulted
only when the worker exited nonzero; a zero exit withnot_executedor
inconclusiveacceptance stayedDONE.refuse_unproven_acceptance()now
turns that intoFAILED / acceptance_failed— in the DAG and in the
single-worker facade the MCP tools use. The sealed evidence still keeps the
honest record, including the real exit code. - The acceptance record now appears in the run report, so a caller can read
what the command actually did instead of inferring it.
Added
- Persistent coding-Skill policy —
~/.config/asha/worker-policy.json(or
ASHA_WORKER_POLICY). When enabled, acommandworker whoseargv[0]
resolves to the configured agent CLI and whosetask_kindiscoding(the
default) is launched ashermes -s clean-code -z "<task>". Skill name,
version, path, SHA-256, overlay digest and the effective argv are sealed into
evidence asskill_preload. - Fail-closed Skill availability — an enabled policy whose Skill is missing
or unreadable blocks the worker before it starts
(BLOCKED / mandatory_skill_unavailable, searched paths reported). - Engineering overlay — an optional markdown file prepended to the task
prompt, for project rules (canonical Enum for finite domains, boundary
validation, SRP) that supplement the Skill instead of forking it. task_kindon a worker —coding(default) ornon_coding; the latter
opts out explicitly instead of relying on prompt interpretation.
Compatibility
- No CLI or MCP signature changed. A missing policy file reproduces v0.6.0
behaviour exactly. antigravityworkers and arbitrary binaries keep their argv byte-for-byte and
receive no Skill injection — Asha does not claim Skill support it lacks.- The acceptance state change is the one behavioural break, and it only affects
runs that were previously reporting success without a proven acceptance.
Verification
- 21 new regression cases (
tests/test_acceptance_audit.py,
tests/test_worker_policy.py). - Real governed runs on a disposable repo: acceptance executed by Asha
("18 passed"),COMPARED / NO_FAILURES, sealed evidence bound to the exact
commits and trees; a failing acceptance yieldsacceptance_failedwith no
seal; a missing Skill yieldsBLOCKEDwith the worker never started; a
non-coding worker gets no preload. - Candidate code from the Skill probe (
StrEnum, boundary parsing, typed
tables) — seeASHA-CLEAN-CODE-DEFAULT-INTEGRATION.md. - CI:
verifypass,fail-closed governance gatepass (PR #25).
Known limitations
- A preloaded Skill is an instruction, not an enforcement. Asha proves the
Skill was resolved, hashed and handed to the CLI; it cannot prove the model
obeyed it. Acceptance and review remain the gates. - The legacy
GovernedSchedulerstill owns its unaudited execution path; it is
not used byasha run, by MCP, or by the release gates.
Full report: ASHA-ENGINEERING-HARDENING-REPORT.md.
v0.6.0 — Task Lifecycle Correlation, Execution Identity & Reproducible Journals
Task lifecycle correlation, execution identity and reproducible journals
Every real execution in Asha now has an identity and a reconstructable trace:
one task_id, one run_id, one worker_id and one execution_id per actual
process, correlated through the journal instead of guessed from timestamps.
Added
- Task lifecycle correlation —
telemetry.with_correlation()is the single
correlation helper; ids ride insidepayload, so the five-field event record is
unchanged and legacy journals stay readable. It never fabricates an id and
fails closed on a conflicting value, so two tasks can never share an event. - Execution identity for the worktree / CLI / DAG runner — one
exec-<12hex>per launched worker command, minted at the launch site and
carried on the settled state, on timeout and on execution-error outcomes.
MCP dispatch passes the id it already owns, so one command never carries two
identities. A blocked or deferred worker gets none. - Per-check validation identity —
run_validation_commandsmints one id per
check at the realsubprocess.runboundary and records it only when a process
actually started. run_specjournal lifecycle — the DAG coordinator emits
execution_startedper dispatched worker, exactly one
sealed/execution_failedper settled worker, and exactly one task-level
terminal event (payload.scope == "task") only after every worker settled.
EventJournalWriternow serialises concurrent appends, so N workers writing
into one run journal cannot interleave records. A journal that cannot be
opened aborts the tool call before anything executes; a journal write error
propagates instead of being read as success.- CLI
run --specwrites the same journal.
Compatibility
Event vocabulary unchanged (execution_started / sealed /
execution_failed); no payload field removed or retyped; new ids and
payload.scope are additive. Journal reading, JournalIntegrity and corruption
reporting unchanged. No public MCP tool-schema change (new test seams are
keyword-only).
Verification
- Full suite 1192 passed, 4 skipped, 0 failed (was 1167 + 4; the +25 are
exactly the new tests), CIverifyandfail-closed governance gateboth
green on the merged head. - End-to-end over the real stdio MCP transport, 9 scenarios: single dispatch,
two independent dispatches, multi-check validation, failing check,run_spec
with one worker / two concurrent / one failing / all failing, a blocked worker,
and an unwritable journal. Concurrency is asserted from real journal timestamp
overlap; the 100-append / 4-thread test keeps every record parseable. - One calibration bound moved (K.6.1 T1 stub budget 82000 → 84000) because the
newDAGCoordinatorhelpers grew that signature stub 2170 → 3159 bytes with
the target body and stub count unchanged — measured, documented in the test,
no assertion removed.
Known limits
- No retry/attempt loop exists: one dispatch is one attempt (unchanged).
- A hard kill between events leaves a truncated journal; integrity reports the
truncation and no synthetic terminal event is written. - Phase 2 (centralized timeout handling) is planned but not part of this
release; the known validation-timeoutlauncheddebt is documented there.
v0.5.0 — Governed Comparison Contract, Acceptance Gate & Scope Accounting
Changes in v0.5.0 (Governed Comparison Contract, Acceptance Gate & Scope Accounting)
- Comparison contract: every governed run records
performed/comparable/reason/detail;NOT_COMPAREDis reported for missing tree identifiers, unparseable baseline failures and per-task inventory mismatch. - Fail-closed identity: a baseline that ran and failed without parseable failure identities yields
baseline_failures: null(never[]), and a green candidate cannot reachDONE(reason: "comparison_inconclusive:baseline_failures_unparsed") -- no seal, no dependents. A baseline that never produced checks keeps the documentedDONEcontract. - Scope accounting:
unaccounted_pathsis written into evidence andSCOPE_INCOMPLETEexits 2 from the CLI. --acceptancegate: a supplied acceptance command must provably pass, and its outcome is sealed with the run.- Baseline comparison executes in its own worktree; the env resolver now handles Windows
.venv/Scripts,deps_rootsource binding, a fail-closed source-identity probe, and cache-free acceptance runs. - Tests: new suites for the acceptance gate, baseline alignment, unparsed baseline identity, CLI scope accounting, the comparison contract, and worktree source binding; frozen-trio anchor advanced to the release commit.
v0.4.2 — Scope Deletion Resilience, AST Syntax Tolerance & In-Place Stack Verification
Changes in v0.4.2 (Phase 11.2 Telemetry Hardening)
- Scope Resolution: Track deletions from
git diff --diff-filter=Dandgit status --porcelain, resolvingTIP_SCOPE_MISSINGfalse positives when branch/commit removes files. - AST Indexer: Guard
SyntaxError,IndentationError, andtokenize.TokenErrorin_index_from, providing safe degradation and surgical context refusal codes. - Stack Verification: Unify
in_place_atomicevidence betweenverify-tipanddispatch-in-placepipelines. - CLI: Structured JSON error payloads for usage and runtime failures under
--json.
v0.4.1 — order-free CLI & snapshot-safe inner loop
Phase 11.1: real-world friction from the Detailist PR #222 run removed, fail-closed governance unchanged.
Fix 1 — order-independent unified CLI (asha/cli.py)
asha /path/to/repo --exec "pytest -q" --base origin/dev
asha --base origin/dev /path/to/repo --exec pytest -q --json
asha --json /path/to/repo --stack b1 b2 b3 --base origin/dev
asha /path/to/repo --context a.py:Foo b.py:Bar
asha /path/to/repo --verify --base origin/dev
asha /path/to/repo --exec -- pytest -q
Global modifiers (--root, --base, --json, --no-color, --ui, --ui-out) are extracted wherever they appear (never after verbatim --); a positional PATH binds root before any mode flag; a mode owns its tokens up to the next known Asha flag (so --exec python -c ... works); conflicting root bindings exit 2 instead of guessing; legacy subcommands (status, inspect, run --spec) and schema-v1 flags (--paths, --no-execute) are unchanged.
Fix 2 — snapshot-safe in_place_atomic
A dirty WIP tree is no longer TIP_DIRTY: the exact pre-execution state (HEAD, index tree, tracked WIP blobs, untracked files, porcelain status set) is snapshotted and restored on failure or scope violation — never git reset --hard HEAD, so uncommitted work survives the inner TDD loop. A pass on a dirty tree returns state: DONE, validation_result: PASS, ready_to_push: false, reason: WIP_UNCOMMITTED_PASS; a clean-tree pass stays commit-bound and pushable. @diff auto-scope includes working-tree changes. Unmerged index entries, in-flight git states and clean-tree diff defects still fail closed before anything runs.
Verification
tests/test_mcp_phase11_1.py(15 new tests: CLI permutations,--verbatim, conflicting root exit 2, dirty-WIP fidelity, out-of-scope rollback, WIP pass + post-commit seal,@diffWIP scope).- Full suite 959 passed / 1 skipped (baseline 944);
ruff0;mypy0 issues in 130 files; governance gates 78 + 73 passed; CI + Asha Governance green on 6f7bbbd.
v0.4.0 — Unified Zero-Friction Entrypoint (one command, one tool)
Highlights & Core Changes
1. Unified MCP Tool (asha) with Deterministic Auto-Routing
- New #1 recommended entrypoint: the
ashatool (registered first; all seven specialized tools stay fully available for backward compatibility). - Arguments (all optional,
rootdefaults to"."):cmd,target,branches,base_ref,run_checks. - Strict, never-guessing precedence:
cmd>branches>target> zero-config.cmd->asha_dispatch_taskwithexecution_mode="in_place_atomic"and automatic@diff/@diff:<base_ref>scope (seals evidence on pass, cleangit reset --hardrollback on failure).branches->asha_verify_stack(root, branches, base_ref)ordered stack lineage + sealed evidence re-verification.target->"file.py:Symbol"selectors (single string, list, or comma-separated) routed to single/batchasha_get_surgical_context; anything not infile:symbolform fails closed asTARGET_FORMAT_INVALID.- Zero-config -> deterministic
asha_statussummary; when the tree is clean, automatically runsasha_verify_tip(auto@diffscope, optionalrun_checks) and seals pre-push tip evidence; a dirty tree reportsready_to_push: false (TIP_DIRTY)with the exact changed scope — never a failure of status reading.
2. Ergonomic One-Command CLI
asha/asha PATH: unified zero-config check on the current/target repository.asha --verify [PATH] [--base REF]: in-place tip verification withrun_checks=True; seals evidence.asha --stack B1 [B2 ...] [--base REF]: ordered stack verification (STACK_*report codes; unhealthy -> exit 1).asha --context FILE:SYMBOL [FILE:SYMBOL ...]: batch surgical AST context in one shot.asha --exec CMD... [--base REF]: atomic in-place governed command with automatic@diffscope and rollback on failure.asha-mcp PATH: a bare existing directory routes directly to the unifiedashatool (deterministic filesystem fact, never a guess).- Exit contract:
0tool ok /1tool refused or routed run failed /2usage error. Existing CLI contracts (schema-v1 governance evaluation,status,inspect,run --spec, unknown flags exit 2) are unchanged.
3. Quality & Baseline
- Version bump:
0.3.0->0.4.0(pyproject.toml,SERVER_INFO, test assertion). - New Phase 11 regression suite (
tests/test_mcp_phase11.py): zero-config sealing, dirty readiness, target routing +TARGET_FORMAT_INVALID, stack routing, in-place dispatch pass + rollback, precedence, CLI flags,asha-mcpbare-path routing, and backward-compatibility guards for the untouched flows. - 0 lint and 0 type issues (
ruff,mypy); zero regressions across the existing baseline (919+ tests). - Docs: README Quickstart now opens with the 1-command / 1-tool workflow; tool reference gains the
asharow;docs/LINUX_SERVER_DEPLOY.mdgains the unified-entrypoint runbook.
4. Operations
- Linux remote server deployment guide (
docs/LINUX_SERVER_DEPLOY.md) and node health smoke verification script (scripts/verify_linux_node.py). - Active GitHub branch protection enforcing the
fail-closed governance gate.