Merge contributor lifecycle update into codex

This commit is contained in:
rob
2026-11-17 20:11:19 +00:00
14 changed files with 146 additions and 32 deletions
+1 -1
View File
@@ -2,4 +2,4 @@
`forge/` holds framework-independent helpers. `templates/` contains independent stack-specific packages; `flask-react/` now includes a descriptor, source payload, fresh context boilerplate, optional GitHub workflow, and a standalone generator. `skills/` is the canonical source for four skills. `profiles/` holds business and personal defaults. `scripts/` provides portable user-level skill distribution. `docs/specifications/` defines interfaces; integrations are optional.
The context skill owns project records, tasks, worktrees, profiles, and design approvals. New delegates lifecycle setup to context. Contributor uses the context lifecycle with Captain/Commander authority and isolated testing. Design uses context for approvals and records. These are contracts, not active skill implementations.
The context skill owns project records, tasks, worktrees, profiles, design approvals, and the canonical lifecycle reference. New delegates lifecycle setup to context. Contributor uses the context lifecycle with Captain/Commander authority, automatic review submission after contributor completion, and isolated testing. Design uses context for approvals and records. Three skill packages are implemented; New remains reserved.
+1 -1
View File
@@ -1,3 +1,3 @@
# Current state
FORGE-F001, FORGE-F002, FORGE-F006, and FORGE-F007 were human accepted and are present on `codex`. F003 and F004 candidates are merged with external validation and acceptance pending. FORGE-F011 is a planned visual design quality follow-up to F003; image-to-editable-Penpot reconstruction remains unproven and requires investigation. F006 provides an independent Flask/React template package and generator, with SQLite, PostgreSQL, MySQL, and MariaDB migrations verified in disposable Docker containers. Windows generation remains untested. The original bootstrap repository remains available; no external retirement was performed. Explicit business/personal profile configuration is implemented. `bortstack-context`, `bortstack-contributor`, and `bortstack-design` packages are present; one skill directory remains reserved. The repository `testtask` entry point is provisioned but blocked because Forge has no application runtime or manual-test hook. No cross-template generator or active legacy-skill migration has been implemented. Captain reports successful external validation of local Penpot 2.18 Docker and integrated MCP, but this session has no Penpot connector/browser. JJ's hands-on workflow has not been tested. Decisions FORGE-001 through FORGE-010 remain accepted. Captain has authorised direct `codex` work until further notice.
FORGE-F001, FORGE-F002, FORGE-F006, and FORGE-F007 were human accepted and are present on `codex`. F003 and F004 candidates are integrated locally with external validation and acceptance pending. The Captain-authorised F004 lifecycle follow-up from `codex-forge-f004-lifecycle` is being integrated into `codex`; it extends F002's accepted context contract without reopening F002. FORGE-F011 is a planned visual design quality follow-up to F003; image-to-editable-Penpot reconstruction remains unproven and requires investigation. F006 provides an independent Flask/React template package and generator, with SQLite, PostgreSQL, MySQL, and MariaDB migrations verified in disposable Docker containers. Windows generation remains untested. The original bootstrap repository remains available; no external retirement was performed. Explicit business/personal profile configuration is implemented. `bortstack-context`, `bortstack-contributor`, and `bortstack-design` packages are present; one skill directory remains reserved. The repository `testtask` entry point is provisioned but blocked because Forge has no application runtime or manual-test hook. No cross-template generator or active legacy-skill migration has been implemented. Captain reports successful external validation of local Penpot 2.18 Docker and integrated MCP, but this session has no Penpot connector/browser. JJ's hands-on and Windows workflow has not been tested. Decisions FORGE-001 through FORGE-011 remain accepted. FORGE-008 authorises direct `codex` work generally; Captain explicitly requested isolation for the F004 lifecycle follow-up.
+4 -1
View File
@@ -1,6 +1,6 @@
# Architecture decisions
FORGE-001 through FORGE-005 were approved planning inputs on 2026-11-17 and are retained with subsequent approved details. FORGE-006 records the approved task identification policy. FORGE-007 supersedes only the PitchInvader pilot clause of FORGE-004; its design ownership and approval policy remain in force. FORGE-008 records Captain's temporary direct-`codex` workflow. FORGE-009 records the approved template migration defaults. FORGE-010 records the approved database set for the Flask/React template.
FORGE-001 through FORGE-005 were approved planning inputs on 2026-11-17 and are retained with subsequent approved details. FORGE-006 records the approved task identification policy. FORGE-007 supersedes only the PitchInvader pilot clause of FORGE-004; its design ownership and approval policy remain in force. FORGE-008 records Captain's temporary direct-`codex` workflow. FORGE-009 records the approved template migration defaults. FORGE-010 records the approved database set for the Flask/React template. FORGE-011 records the contributor finalisation and integration policy.
## FORGE-001 — Technology-Agnostic Project Bootstrap Architecture
Status: Accepted. Date: 2026-11-17. Rationale: project lifecycle must apply across stacks. Consequences: Core has no Flask, React, React Native, or other framework dependency; independently maintained templates own stack-specific behavior. Generated projects have no Forge runtime dependency. Supersedes: none.
@@ -31,3 +31,6 @@ Status: Accepted. Date: 2026-11-17. Rationale: generated applications must remai
## FORGE-010 — Multi-Database Flask/React Template
Status: Accepted. Date: 2026-11-17. Rationale: Captain wants the generated application to support multiple database engines and selected SQLite, PostgreSQL, MySQL, and MariaDB for FORGE-F006. Consequences: local generation defaults to persistent SQLite; PostgreSQL, MySQL, and MariaDB are opt-in Compose overlays with their respective Python drivers and configuration examples. Validate generated migrations against all four engines. Database credentials belong in private project configuration, never in tracked production files. Supersedes: the inherited assumption that MySQL is the default generated database.
## FORGE-011 — Contributor Finalisation and Verified Integration
Status: Accepted. Date: 2026-11-17. Rationale: completed contributor tasks must not accumulate as uncommitted or unintegrated worktrees. Consequences: `bortstack-context` owns one state and evidence contract; `bortstack-contributor` automatically starts ordinary commit/push/review submission when JJ reports task completion, subject to repository policy and required checks. Captain approval precedes merging contributor PRs. Integrated requires combined-application verification; Closed requires human acceptance. Contributor-created temporary Docker test containers remain until JJ explicitly requests cleanup, subject to safety constraints. Windows exercise is mandatory before F004 is production-ready. The Captain explicitly requested an isolated branch/worktree for this follow-up, an exception to FORGE-008's current default. Supersedes: no earlier accepted decision; clarifies FORGE-F002 and FORGE-F004 lifecycle requirements.
+6 -6
View File
@@ -1,13 +1,13 @@
# Handoff
Current work: FORGE-F006 migrated the tracked `flask-react-auth-base` source at `ff139bf5f28f4604b4a7108f4ee26608dea9924e` into Forge on `codex`, starting from `bc6b6d2`. Captain accepted F006 on 2026-11-17; its status is Complete. The original source repository was read and remained clean/unchanged. Direct `codex` work follows FORGE-008. No external application, provider, or production infrastructure was modified.
Current work: Captain authorised integration of the contributor lifecycle follow-up from `codex-forge-f004-lifecycle` (`c2d4561`) into `codex`. The source worktree is `/tmp/bortstack-forge-f004-lifecycle`, baseline `934e62c`; the target had advanced to `900bd6c` with FORGE-F011 planning. F002 remains Complete. F004 is integrated locally but still pending JJ's external validation and human acceptance. The original F004 worktree remains preserved.
Implementation: `templates/flask-react/` now contains a descriptor, independent source payload, Python generator, fresh neutral context boilerplate, and optional GitHub workflow. Generated projects do not need GitHub, SWAG, Resend, a production host, or Forge at runtime. Email is disabled by default, branding is project-specific, and optional SWAG uses a separate Compose overlay. Under FORGE-010, the generated Compose base uses persistent SQLite; PostgreSQL, MySQL, and MariaDB have opt-in database overlays and example environment files. The API image includes psycopg and PyMySQL. Existing `roborto-*` skills and Forge distribution tooling are untouched.
Implementation: `bortstack-context/references/task-lifecycle.md` is the canonical state, transition, evidence, identifier and integration contract. Contributor starts finalisation from natural completion language and owns ordinary-language review handoff. Captain approval, combined checks and human closure are separate gates. `docs/validation/contributor-lifecycle.md` covers acceptance scenarios A-I. FORGE-F011 remains Planned with its design-quality investigation and outstanding decisions intact. No external project, provider setting, production infrastructure or installed skill was modified.
Validation: Forge `python3 -m unittest discover -s tests -v` passed 15 tests and `python3 scripts/validate-skills.py` passed. A disposable `Orion Starter` generated at `/tmp/forge-f006-orion2` passed 14 backend tests in an ephemeral Docker container, SQLite migration upgrades, Compose configuration, and API/nginx image builds. A fresh `/tmp/forge-f006-orion3` passed base and optional SWAG-overlay Compose configuration, clean `npm ci`, 16 frontend tests, lint, and build in a Node container. A further disposable `/tmp/forge-f006-browser-trial` passed 23 Playwright checks with one intentional skip after Chromium OS libraries were installed in the ephemeral runner. A new `Matrix Trial` generation passed base and all database-overlay Compose configuration, API image build, and live Alembic upgrades on SQLite, PostgreSQL, MySQL, and MariaDB. Disposable database containers, networks, and volumes were removed. Generator tests cover local-only mode, optional local Git, collision refusal, copied capabilities, neutral identity, no active GitHub workflow, and the database overlays. `git diff --check` passed.
Validation: Branch checks passed 17 tests, skill validation, installer dry-run, and `git diff --check`. Run the same checks on the combined `codex` tree before committing integration. Local Git fixtures cover sequential tasks, failed combined checks, failed push preservation and paths with spaces; context fixtures cover historical and conflicting IDs. These tests do not prove actual provider PR submission or JJ's conversational/Windows Docker workflow.
Limitations: Host Python lacked Flask, so a direct host test failed; an initial network-disabled pip install and API build also failed on dependency resolution. Container validation succeeded using available dependency/image cache and normal Docker networking. Host npm was absent, but a clean generated-project `npm ci` and subsequent checks passed inside Node Docker. `npm ci` reported 14 advisories in development dependencies (5 moderate, 7 high, 2 critical); `npm audit --omit=dev` reported zero production advisories. The first Playwright attempt failed because the minimal runner lacked Chromium libraries; after installing those libraries inside an ephemeral container, the suite passed. The full backend test suite has not been run separately on PostgreSQL, MySQL, or MariaDB; live migration checks passed on each. Windows generation and live email/hosting remain unverified. The original bootstrap remains available; retiring it would require a separate change outside Forge. Forge `testtask` remains blocked because Forge has no application runtime.
Limitations: Windows and JJ hands-on testing remain mandatory before F004 is production-ready. Real provider push/PR and full combined-application UI/API verification are unavailable in this Forge-only exercise. The local `testtask` wrapper remains provisioned but blocked without an application runtime/hook. F003 retains its separate pending approval. F006 is accepted and its original source repository remains untouched.
Next action: F005 may use the accepted descriptor and generator. F008's F006 dependency is also satisfied. F003 and F004 still await their separate external validation and acceptance. FORGE-F011 is planned and does not close F003's outstanding checks. No push or deployment has occurred.
Next action: Finish combined Forge checks, record the integration commit and keep F004 open for JJ's Windows, Docker, provider and conversational acceptance exercises. F005 may use the accepted F006 descriptor and generator; F008's F006 dependency is satisfied. FORGE-F011 planning needs Captain review. No push or deployment has occurred.
Task preparation (2026-11-17): On `codex` from `934e62c`, inspected repository records and the clean checkout, ran the context task-ID audit, and searched for `FORGE-F011`; no collision was found. Added context records only. No skill implementation, application code, Penpot file, or external project was changed. Validate the task register and scoped diff; no runtime test applies to this documentation-only preparation. Captain review of the proposed acceptance criteria and open technical decisions is the next human action; F011 remains Planned.
FORGE-F011 preparation (2026-11-17): On `codex` from `934e62c`, the prior planning pass inspected repository records and clean checkout, ran the context task-ID audit, and found no F011 collision. It added context records only; no skill implementation, application code, Penpot file, or external project changed. F011 remains Planned.
+4
View File
@@ -16,6 +16,8 @@ Acceptance: demonstrate lifecycle and collision checks with new and legacy repos
Implementation record (2026-11-17): Added the canonical skill, snapshot command reference, read-only task ID/worktree audit, ZIP snapshot entry point, and explicit blocked `testtask` entry point. Tests cover collision handling for new and legacy IDs and safe snapshots of edited/untracked files. The skill defines lifecycle gates and preservation of unfinished work. Runtime manual testing remains unavailable until Forge has a task-specific hook; Windows is untested.
Contributor integration follow-up (2026-11-17): F002 remains Complete. Its accepted context skill is being extended with the canonical state-transition and evidence reference under the Captain-authorised F004 lifecycle follow-up; this does not reopen or renumber F002. The reference owns collision resolution and combined-integration gates for other skills.
## FORGE-F003 — Implement `bortstack-design`
Status: Merged into local `codex`; Captain design approval and external validation pending. Priority: High. Dependency: FORGE-F002, Complete and integrated into local `codex`; no dependency blocker. Implementation was committed on `codex-forge-f003` at `/tmp/bortstack-forge-f003` and fast-forward merged into `codex` on 2026-11-17. Planning reconciliation remains preserved separately at `/tmp/bortstack-forge-f003-reconciliation`.
@@ -44,6 +46,8 @@ Acceptance: test two consecutive contributor tasks. Submit the first for review
Implementation record (2026-11-17): Added the canonical contributor skill and review-handoff reference. A disposable Git test exercised two consecutive task branches/worktrees, selective staging, preserved untracked work, and no merge into the integration branch. The first review was represented by a local marker, not a provider PR. Real PR submission, JJ's Windows installation, manual Docker testing, and JJ's hands-on workflow remain unverified; do not mark Complete until the required human acceptance and external checks are resolved.
Contributor integration follow-up (2026-11-17): Captain authorised a dedicated `codex-forge-f004-lifecycle` branch at `/tmp/bortstack-forge-f004-lifecycle`, based on `934e62c`, to strengthen the existing F004 candidate and shared context contract. The contributor skill now initiates finalisation from natural completion language and uses context's canonical lifecycle; review submission, Captain-controlled integration, combined checks, recoverable failure handling, task-ID conflict resolution, Docker retention, and nontechnical messaging have explicit gates. Acceptance scenarios A-I are recorded in `docs/validation/contributor-lifecycle.md`; Windows and real provider/JJ exercises remain open. F004 stays pending external validation and human acceptance; do not mark it Complete from this follow-up alone.
## FORGE-F005 — Implement `bortstack-new`
Status: Planned. Priority: High. Dependencies: FORGE-F002, FORGE-F006, FORGE-F007.
+2 -2
View File
@@ -1,5 +1,5 @@
# Integration and skill interfaces
`bortstack-context`: project overview/current state, decisions, tasks, handoffs, task-scoped branches/worktrees, design references/approvals, and profile interpretation for new and existing repositories. `bortstack-new`: template selection, generation orchestration, initial configuration and profile, optional Git repository configuration; delegates lifecycle conventions to context. `bortstack-contributor`: onboarding, permitted task creation and implementation, PR preparation, contributor tests and handoff; preserves JJ's task creation, Captain/Commander terminology, isolated branches, and disposable Docker test environments. Manual-testing containers remain available until the contributor is instructed to remove them. `bortstack-design`: visual design orchestration, optional Penpot/MCP operations, concepts, approved handoff, code guidance, and visual QA; delegates task status and approvals to context. Design-dependent implementation needs an approved design or an explicit recorded override.
`bortstack-context`: project overview/current state, decisions, tasks, handoffs, task-scoped branches/worktrees, design references/approvals, and profile interpretation for new and existing repositories. Its `references/task-lifecycle.md` is the single source for task states, transition evidence, integration and closure gates, project-prefixed IDs, collision handling, and worktree preservation. `bortstack-new`: template selection, generation orchestration, initial configuration and profile, optional Git repository configuration; delegates lifecycle setup to context when implemented. `bortstack-contributor`: onboarding, permitted task creation and implementation, automatic finalisation after JJ reports completion, PR preparation, contributor tests and plain-language handoff; consumes context's lifecycle rather than duplicating it. It preserves JJ's task creation, Captain/Commander terminology, isolated branches, and disposable Docker test environments. Contributor-created manual-testing containers remain available until JJ explicitly requests removal, subject to safety constraints. `bortstack-design`: visual design orchestration, optional Penpot/MCP operations, concepts, approved handoff, code guidance, and visual QA; delegates task status and approvals to context. Design-dependent implementation needs an approved design or an explicit recorded override.
Git providers and Penpot are optional adapters. A provider integration must declare authentication, supported operations, failure behavior, and local-only fallback; no provider is assumed. Penpot absence must not block context or non-design tasks. No MCP server or provider integration is configured in this task.
Git providers and Penpot are optional adapters. A provider integration must declare authentication, supported operations, failure behavior, and local-only fallback; no provider is assumed. A committed task is not a verified review submission, and a Git merge is not verified application integration. Captain approval precedes contributor-PR merging; combined-application checks precede Integrated, and human acceptance precedes Verified / Closed. Penpot absence must not block context or non-design tasks. No MCP server or provider integration is configured in this task.
+17
View File
@@ -0,0 +1,17 @@
# Contributor lifecycle acceptance exercises
Use only disposable repositories and task-owned test resources. `python3 -m unittest tests/test_contributor_workflow.py tests/test_context.py` exercises the local Git and identifier fixtures on Linux. These fixtures validate preservation and ordering; they do not simulate a provider PR, a human approval, or Windows. For every exercise, record the task state and evidence fields from `skills/bortstack-context/references/task-lifecycle.md`.
| Scenario | Repeatable procedure and expected result | Current evidence |
| --- | --- | --- |
| A — Sequential tasks | In a disposable repo, complete Task A in its worktree, inspect/stage intended files, commit and submit it for review, then start independent Task B from the integration baseline. A remains recoverable and unmerged; B excludes A's commit. | Automated local fixture; review marker only, not a real PR. |
| B — Combined failure | Pass Task A's isolated checks, approve and integrate it in a disposable target, then make a combined test fail. Record failure and keep A open; do not mark Integrated or Closed. | Automated local fixture checks the failure and open record. Real UI/API checks require an application. |
| C — Parallel development | Create two independent worktrees from the same appropriate baseline, record both targets/dependencies, and verify neither branch contains the other's commit. | Automated local fixture. |
| D — Failed push/PR | Commit Task A, use a deliberately failing disposable remote or unavailable provider, and run the submission gate. Verify the local commit/worktree survive, state remains pre-review, and Commander receives a plain-language saved-work explanation. | Automated failed-push fixture verifies preservation; provider dialogue pending live exercise. |
| E — Docker testing | Start a uniquely named disposable task container, complete and submit the task, verify the container remains, then have Commander explicitly request cleanup and remove only that container. | Documented procedure; live Docker exercise with JJ pending. |
| F — Legacy tasks | Inventory `TASK-001` and `FORGE-F001` beside a new prefixed ID. Verify stable IDs and no automatic rewrite. | `tests/test_context.py` fixture. |
| G — Task-ID conflict | Put the same new ID in two task registers; run `python3 scripts/context_audit.py first.md second.md`. Expect collision locations and nonzero exit before integration. Captain authorises any renumbering; preview and update all references, then rerun. | `tests/test_context.py` fixture detects collision; authorised renumbering is a documented manual procedure. |
| H — Windows | On JJ's Windows machine, use Codex CLI, Git, and Docker with a disposable repo under a path containing spaces. Complete and submit a task through conversation, check remote branch/PR, leave the test container until requested cleanup, and verify another task can start. Use PowerShell for any displayed shell command; avoid Bash assumptions and administrator privileges. | Mandatory external acceptance gate, unverified here. |
| I — Nontechnical completion | Ask Commander to say "everything works" after exact-candidate manual testing. Observe Codex identify the task, inspect files, test, commit, push, submit review, and report saved/submitted status without asking Commander to run Git. Repeat with a failed submission and verify truthful ordinary-language recovery message. | Skill instructions and local Git fixtures; JJ's conversational end-to-end exercise pending. |
After Captain approval, repeat a successful integration exercise against the latest designated baseline, including affected screens, navigation, routes, APIs and dependencies as applicable. A Git merge is only one step. Record combined checks separately from isolated checks. Do not mark F004 production-ready for JJ until H and I pass on his environment and real provider submission is verified where configured.