Skip to content

feat(repos_sync): check Heart version_skew and Hands workspaces.yaml identity (stamper deferred) #370

Closed

Description

@Jammy2211

Overview

The prompt asks repos_sync.py --write to stamp the organ config surfaces (Heart version_skew:/smoke:, Hands workspaces.yaml) from the body map. Research at plan time found the stamper premature: those blocks changed ~3 times in six weeks, workspaces.yaml twice ever, there are zero adopters, and the design doc itself files it as "demand-gated, later". What is genuinely missing today is cheaper: Heart's version_skew: block is entirely unchecked by repos_sync.py --check, and PyAutoHands/autohands/config/workspaces.yaml claims in its header that the check flags drift but no leg reads it. This task ships those two drift checks and records the stamper as deferred.

Plan

  • Extend the existing PyAutoHeart/config/repos.yaml leg to validate version_skew: identity against the manifest.
  • Add a PyAutoHands/autohands/config/workspaces.yaml membership leg (run_all, libraries name+package, slow_skip_default).
  • First tests for check_heart, tests for the new Hands leg.
  • Record the stamper deferral and its evidence in the issue and the completion record.
Detailed implementation plan

Work Classification

Library (Mind organ source) — ships via /ship_library.

Affected Repositories

  • PyAutoMind (primary) — read-only reads of Heart/Hands config files in the canonical checkouts; no edits there.

Branch Survey

Repository Current Branch Dirty?
./PyAutoMind main clean

Suggested branch: feature/repos-sync-config-checks
Worktree root: ~/Code/PyAutoLabs-wt/mind-workflow/ (shared by the mind-workflow bundle; one branch at a time)

Implementation Steps

  1. scripts/repos_sync.py check_heart (~:348-390): after the existing polled-repo / owner / smoke membership checks, validate version_skew: — each key is a manifest repo, each library is a manifest repo, and each package equals that library's manifest package:; a version_skew entry whose library has no package: in the manifest is a problem.
  2. New check_hands_workspaces(root, repos): read PyAutoHands/autohands/config/workspaces.yaml (skip when absent, like every other leg); run_all[*].repo, libraries[*].name, slow_skip_default[*] must be manifest repos; libraries[*].package must equal the manifest package:. Register it in the checks dict (~:1256-1275) under the label PyAutoHands/autohands/config/workspaces.yaml so --only selects it.
  3. Tests: new tests/test_repos_sync_config_checks.py using a tmp root + minimal manifest dict, following the sys.path.insert(... "scripts"); import repos_sync idiom in tests/test_repos_sync_hygiene_coverage.py:24-26: check_heart clean / unknown library / package mismatch / missing block tolerated; Hands leg clean / unknown repo / wrong package / absent file skipped.
  4. Run python3 scripts/repos_sync.py --check against the canonical workspace: both legs must be OK on today's real files.
  5. Completion record: stamper deferred (demand-gated), churn evidence, and the precise remaining hand-mirrored fields (chain, run_all short keys, report dirs, release matrix order) so a future adopter-driven task starts from the list.

Key Files

  • scripts/repos_sync.py — check_heart, new Hands leg, checks dict
  • tests/test_repos_sync_config_checks.py (new)
  • PyAutoHeart/config/repos.yaml, PyAutoHands/autohands/config/workspaces.yaml — read only

Not in scope (deferred)

The stamper itself (YAML marker family, manifest library: key, stamped blocks, Heart/Hands PRs). The comments/docstrings firewall exemption stays REJECTED per complete/2026/08/autohands-firewall-allowlist.md.

Original Prompt

Click to expand starting prompt

Teach repos_sync --write to stamp organ config surfaces

Type: feature
Target: pyautomind
Themes:

  • mind-workflow
    Difficulty: hard
    Autonomy: supervised
    Priority: low
    Filed: 2026-08-17 (backfilled from git)

The design's own endgame for tenant-firewall drift, specified in
docs/pyautobrain/pyautoscientist_generalisation_assessment.md §8-4 and
restated in docs/pyautobrain/pyautoscientist_phase3_research.md ("Demand-
gated, later"): teach scripts/repos_sync.py --write to stamp the organ
config surfaces from the body map + per-organ policy fields, the way it
already stamps doc blocks. Quoting the assessment: "That turns 'edit five
mirrors' into 'edit one file, regenerate' … This is the only real
engineering in the whole plan
, and it removes his own hand-mirroring burden,
so it pays for itself even with zero adopters."

Filed 2026-08-17 from the tenant-firewall drift-clear
(PyAutoMind#198), whose research pass found this remedy named in the design
but never filed anywhere in Mind. Context there: the allowlist grew 72→109
files in five weeks of reactive patches; #198's PR-time CI gates stop drift
landing, this task removes the hand-maintained mirrors that generate it.

Scope sketch (to be refined at start_dev)

  • Candidate surfaces to stamp: Heart config/repos.yaml blocks
    (version_skew:, the smoke: block maintenance: tenant-firewall drift — refactor-first clear + PR-time gates #198 introduces), Hands
    autohands/config/workspaces.yaml, and any organ constant table still in
    the allowlist that is identity-derivable.
  • Needs per-organ policy fields the body map deliberately does not carry
    (dependency chains, package import names, short keys) — decide where policy
    lives (per-organ policy YAML consumed by the stamper vs schema extension),
    honouring the body map's "identity only" doctrine.
  • The stamper must be drift-checked itself (the check legs already exist —
    stamping makes them tautologies for stamped blocks, which is the point).

Not in scope

  • The firewall check semantics (unchanged).
  • The comments/docstrings exemption — CONSIDERED AND REJECTED, recorded in
    complete/2026/08/autohands-firewall-allowlist.md; do not re-propose.

Activity

  1. Jammy2211 commented on Aug 29, 2026

    @Jammy2211
    CollaboratorAuthor

    PR opened: #373 — Heart YELLOW acknowledged by the human for the bundle (workspace-validation timeout autolens_test delaunay_mge.py; no release rehearsal), unrelated to this change. Tests: 296 passed; both new legs OK on the real Heart/Hands files. Stamper deferred (demand-gated) — see PR body. Next: /prm (after #372 if they conflict on repos_sync.py).

  2. added a commit that references this issue on Aug 29, 2026
  3. Jammy2211 commented on Aug 30, 2026

    @Jammy2211
    CollaboratorAuthor

    Shipped

    PR #373 — MERGED.

    The prompt asked repos_sync.py --write to stamp Heart's version_skew:/smoke: and Hands' workspaces.yaml from the body map. Measured before issuing: those Heart blocks changed ~3 times in six weeks, workspaces.yaml twice ever, zero adopters, and the design doc itself files the stamper as "demand-gated, later". The stamper is therefore DEFERRED.

    What shipped is the cheaper gap it would have closed as a side effect: Heart's version_skew: block was entirely unchecked by --check, and PyAutoHands/autohands/config/workspaces.yaml claimed in its header that the check flags drift while no leg read it. check_heart now validates version_skew: (keys and library are manifest repos; package equals the library's manifest package:; a library with no manifest package is a problem; absent block tolerated). New leg PyAutoHands/autohands/config/workspaces.yaml checks run_all[*].repo, libraries[*].name + package, slow_skip_default[*]; absent file skipped; --only-selectable.

    Validation: 15 tests in tests/test_repos_sync_config_checks.py — the first ever for check_heart — written to fail on the unmodified script (12 failed / 3 passed), 15 pass after; suite 296 passed; both legs OK on the real Heart/Hands files.

    Record: complete/2026/08/repos-sync-config-checks.md

  4. added a commit that references this issue on Aug 30, 2026
  5. added 2 commits that reference this issue on Oct 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions