Task · SKT-0005.09

Make git blueprint sources and apply state explicit

Description

Make the custom Git-source lifecycle understandable and preflight failures before users wait for automatic behavior that does not exist. Surface the full configured-to-fetched-to-staged-to-loaded transition and the required restart.

Acceptance Criteria

Definition of Done

Implementation Plan

  1. Test and implement strict Git-source validation plus a guided add-and-fetch operation without changing the apply-on-restart contract.\n\n2. Persist and expose fetched SHA/file/effective-name state separately from loaded SHA and pending restart.\n\n3. Update the source-management UI and documentation with deployment-specific restart guidance and loaded/skipped results.\n\n4. Run focused Go/UI/docs checks, integrate shared control wiring, obtain root CodeRabbit review, then run the full gate and inventory proof.

Formatting correction to the preceding single-line rendering:

  1. Test and implement strict Git-source validation plus a guided add-and-fetch operation without changing the apply-on-restart contract.
  2. Persist and expose fetched SHA/file/effective-name state separately from loaded SHA and pending restart.
  3. Update the source-management UI and documentation with deployment-specific restart guidance and loaded/skipped results.
  4. Run focused Go/UI/docs checks, integrate shared control wiring, obtain root CodeRabbit review, then run the full gate and inventory proof.

Implementation Notes

Continuation authorized with a fresh CodeRabbit budget and live reference-stack/standing-host verification. Root owns all external writes and will record only de-identified evidence in this public tracker.

Wave A implementation complete pending standing-host verification. Strict source validation, guided add-and-fetch, fetched/observed/loaded lifecycle state, restart guidance, and skipped-result reporting are implemented. CodeRabbit review found and the implementation repaired a concurrent source-update race by serializing persisted read-modify-write state while rejecting stale network results. Focused Go/UI/docs checks, race/vet, the full make gate, and the dry-run inventory completed successfully.

Standing-host verification passed at exact image revision b6c4ea5. A public source was added and fetched at that SHA: 26 files and effective names were exposed with pending restart true. After a Compose restart, loaded SHA equalled fetched SHA, pending restart cleared, and all 26 intentionally deselected files were reported explicitly while the selected built-in remained the only active blueprint. The temporary source and staged files were removed and a clean restart left no pending changes.

Final Summary

Implemented strict Git-source validation, guided add-and-fetch, separate fetched/observed/loaded lifecycle state, restart guidance, and loaded/skipped reporting. Verified with focused Go and UI tests, CodeRabbit, make gate, dry-run inventory, and an exact-head standing-host add/fetch/restart/cleanup exercise.

References

View the source file on GitHub