FORGE-F012 Document Penpot editor connection preflight and recovery
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
# Current state
|
||||
|
||||
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` was integrated into `codex` at `727a64e` after combined Forge checks; 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.
|
||||
|
||||
FORGE-F012 is an isolated design-skill maintenance candidate at `/tmp/bortstack-forge-f012`, based on `68432c2`. Its editor-connection preflight and recovery guidance are pending review, integration, and human acceptance. The Captain explicitly requested an isolated worktree for F012; FORGE-008 remains the general direct-`codex` policy. No live Penpot behavior is claimed by this documentation candidate.
|
||||
|
||||
@@ -11,3 +11,5 @@ Limitations: Windows and JJ hands-on testing remain mandatory before F004 is pro
|
||||
Next action: 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.
|
||||
|
||||
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.
|
||||
|
||||
FORGE-F012 candidate (2026-11-18): Captain requested an isolated worktree for Penpot editor connection reliability, overriding FORGE-008 for this task only. Branch `codex-forge-f012` at `/tmp/bortstack-forge-f012` starts from `68432c2`, targeting `codex`. The design skill and Penpot reference distinguish MCP availability, editor connection, and target-verified inspection; the latter gates edits. Recovery preserves the last confirmed design and checks uncertain writes before retrying. Focused contract tests were added. On the isolated branch, 20 tests, skill validation, installer dry-run, task ID audit, and `git diff --check` passed. Implementation commit is pending. No Penpot design, external project, installed skill, or production infrastructure changed. Live editor/browser and Windows validation remain unverified. Review and Captain-authorised integration remain pending; human acceptance is required before F012 closes.
|
||||
|
||||
@@ -109,6 +109,15 @@ Acceptance proposed: demonstrate at least two visually distinct styled direction
|
||||
|
||||
Open technical decisions for implementation briefing: define permitted reference sources and provenance/usage recording; choose whether and when image generation improves exploration; set measurable quality and fidelity review criteria; determine the reconstruction method and limits for text, vectors, imagery, components, and responsive variants; select the Forge-owned example and approval artifact; decide what evidence can validate Windows and non-MCP operation. Treat reconstruction feasibility as an investigation outcome, not an assumed capability.
|
||||
|
||||
## FORGE-F012 — Penpot Editor Connection Reliability
|
||||
Status: Implementation Complete; isolated review and human acceptance pending. Priority: Small maintenance improvement. Owner: Codex. Dependency: FORGE-F003 design skill; its separate acceptance remains pending. Branch/worktree: `codex-forge-f012` at `/tmp/bortstack-forge-f012`; baseline `68432c2`; integration target `codex`. Captain's explicit request for an isolated task worktree is a task-specific exception to FORGE-008. Provider remote/PR, integration commit, combined validation, and human acceptance: pending.
|
||||
|
||||
Scope: Document MCP service availability, active editor connection, and successful inspection of the intended design as separate states. Require the verified inspection before mutation, and give contributors browser guidance and a safe recovery sequence for editor disconnection. Keep Penpot operations runtime-discovered and optional. Do not edit PitchInvader, installed skills, or Penpot designs as part of this maintenance task.
|
||||
|
||||
Implementation: The design skill and Penpot operations reference now require a target-verified, non-destructive inspection before edits and after interruptions. Recovery stops edits, preserves the last confirmed state and references, asks the contributor to reactivate/reconnect the intended editor, checks uncertain writes, and resumes only after inspection succeeds. Focused contract tests cover these requirements. No live editor session was exercised for this documentation change.
|
||||
|
||||
Validation (isolated branch, 2026-11-18): 20 unittest tests passed, including three focused connection-contract checks; the skill validator accepted all three implemented packages; installer dry-run included `bortstack-design`; task ID audit and `git diff --check` passed. Manual Penpot/browser validation and Windows behavior remain unverified; this task does not close F003's existing external acceptance gates. Next action: review the isolated candidate, then integrate only with Captain authorisation and combined checks; record human acceptance separately.
|
||||
|
||||
## Scheduling
|
||||
|
||||
Start with F002. F003 and F004 can follow F002 independently; F006 can proceed after F001. F007 follows F002. F005 follows F002, F006, and F007. F008 follows F006. F010 follows F002 and F004. F011 builds on F003 without closing its separate acceptance checks. F009 remains deferred until after F005. Dependency readiness does not authorise implementation.
|
||||
|
||||
@@ -17,7 +17,7 @@ Generate at least two meaningfully different concepts when the task calls for al
|
||||
|
||||
## Optional Penpot connection
|
||||
|
||||
Follow `references/penpot-operations.md`. Discover the available Penpot server and MCP tools at runtime; do not assume a specific URL, port, token, or tool name. Confirm project/file access and create/edit capability before mutation. MCP can create and modify native editable objects when available. If MCP is unavailable, prepare importable vector sources, use the Penpot UI for import/editing when accessible, and give Captain a precise manual path. Record which path was actually tested. Penpot absence does not block unrelated context or non-design tasks. Support local and future self-hosted Penpot on Linux and Windows without changing Forge Core.
|
||||
Follow `references/penpot-operations.md`. Discover the available Penpot server and MCP tools at runtime; do not assume a specific URL, port, token, or tool name. Before each design modification or resumed editing session, identify the intended file and page, confirm the editor connection, and complete a non-destructive inspection of that design. MCP service availability alone does not prove editor connectivity; only a successful inspection of the intended design establishes operational readiness. Stop mutations and follow the reference's recovery procedure when inspection or a design operation fails. MCP can create and modify native editable objects when available. If MCP is unavailable, prepare importable vector sources, use the Penpot UI for import/editing when accessible, and give Captain a precise manual path. Record which path was actually tested. Penpot absence does not block unrelated context or non-design tasks. Support local and future self-hosted Penpot on Linux and Windows without changing Forge Core.
|
||||
|
||||
## Approval and handoff
|
||||
|
||||
|
||||
@@ -4,11 +4,34 @@ Penpot is optional and outside Forge Core. Treat server URL, authentication, wor
|
||||
|
||||
## MCP route
|
||||
|
||||
1. Discover the connected Penpot MCP tool and inspect its supported operations. A Docker container being up is not proof that the current Codex session can call MCP.
|
||||
2. Confirm access to the intended project and file, then inventory existing elements before changes.
|
||||
3. Create a versioned concept page/board or duplicate. Keep text as text and shapes as shapes. Record returned references and any unsupported operations.
|
||||
4. After refinement, inspect the result and compare its elements with the prior version. Export a preview only as evidence; retain the editable source.
|
||||
5. Record server version and platform as observed, without treating a Linux check as Windows validation.
|
||||
### Connection states and preflight
|
||||
|
||||
- **A — MCP service available:** Codex can discover or invoke the Penpot MCP service. This proves only that the service is reachable.
|
||||
- **B — Editor connected:** The intended design file is open in Penpot with an active editor MCP connection. Tool discovery does not establish this state.
|
||||
- **C — Design operations verified:** A non-destructive inspection completes and its result identifies the intended file and page or unmistakably matches their known design content. Only C permits modification.
|
||||
|
||||
Before each modification, and again after a connection interruption or extended idle period:
|
||||
|
||||
1. Discover the Penpot MCP service and the tools actually exposed in this session. Do not infer availability from a running container or earlier session.
|
||||
2. Identify the intended project, design file, and page from the task and design references. If ambiguous, resolve the target before editing.
|
||||
3. Confirm or establish the active editor MCP connection for that file using the editor UI and any connection-status operation actually exposed. Keep the intended design file open during MCP operations and maintain its active editor connection. An open tab by itself is not proof of B or C.
|
||||
4. Use an exposed read-only operation to inspect the intended design, such as its page or element inventory. Do not use an edit as a connection test.
|
||||
5. Check the inspection result against the intended file and page. A successful response about another file is not readiness. If the service has no reliable editor-status operation, this successful, target-verified inspection is the operational readiness check.
|
||||
6. Record A/B/C readiness and the inspected file/page reference, or report the failed step as a blocker. Begin edits only at C.
|
||||
|
||||
Prefer keeping the Penpot tab active during extended design sessions. If operations become unreliable, reactivate the intended tab and reconnect the editor. An observed editor disconnection is evidence; browser background-tab throttling is a possible cause, not a diagnosis without further evidence. Firefox and other compatible browsers are supported; no particular browser is required. Use the configured instance rather than assuming a port or hardcoded URL.
|
||||
|
||||
### Safe recovery
|
||||
|
||||
When an inspection or modification fails because the editor may be unavailable:
|
||||
|
||||
1. Stop further design modifications. Preserve the last confirmed design state, file/page references, and any returned operation results. Do not assume a failed write either applied or rolled back.
|
||||
2. Explain the likely editor connection issue to the contributor, distinguishing a confirmed disconnection from a possible inactive-tab interruption.
|
||||
3. Ask the contributor to reactivate the intended Penpot tab and check or restore its editor MCP connection. Reopen the intended file if it was closed.
|
||||
4. Repeat the non-destructive inspection and verify the intended file and page. Reconcile any uncertain prior write against the last confirmed state before retrying it.
|
||||
5. Resume modifications only after State C is re-established. If inspection still fails, record the blocker and use the non-MCP route only when it fits the task and preserves editable source and approval references.
|
||||
|
||||
After readiness, create a versioned concept page/board or duplicate. Keep text as text and shapes as shapes. Record returned references and any unsupported operations. After refinement, inspect the result and compare its elements with the prior version. Export a preview only as evidence; retain the editable source. Record server version and platform as observed, without treating a Linux check as Windows validation.
|
||||
|
||||
## Non-MCP route
|
||||
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
"""Keep the design skill's editor-readiness and recovery guidance aligned."""
|
||||
|
||||
import unittest
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1] / "skills/bortstack-design"
|
||||
SKILL = (ROOT / "SKILL.md").read_text(encoding="utf-8")
|
||||
OPERATIONS = (ROOT / "references/penpot-operations.md").read_text(encoding="utf-8")
|
||||
|
||||
|
||||
class PenpotConnectionContractTests(unittest.TestCase):
|
||||
def test_skill_requires_verified_inspection_before_modification(self):
|
||||
self.assertIn("non-destructive inspection", SKILL)
|
||||
self.assertIn("only a successful inspection", SKILL)
|
||||
self.assertIn("Stop mutations", SKILL)
|
||||
|
||||
def test_reference_distinguishes_service_editor_and_verified_design(self):
|
||||
for state in ("A — MCP service available", "B — Editor connected", "C — Design operations verified"):
|
||||
with self.subTest(state=state):
|
||||
self.assertIn(state, OPERATIONS)
|
||||
self.assertIn("Only C permits modification", OPERATIONS)
|
||||
self.assertIn("intended file and page", OPERATIONS)
|
||||
self.assertIn("read-only operation", OPERATIONS)
|
||||
|
||||
def test_recovery_verifies_target_and_uncertain_writes(self):
|
||||
self.assertIn("Stop further design modifications", OPERATIONS)
|
||||
self.assertIn("Do not assume a failed write either applied or rolled back", OPERATIONS)
|
||||
self.assertIn("Repeat the non-destructive inspection", OPERATIONS)
|
||||
self.assertIn("Reconcile any uncertain prior write", OPERATIONS)
|
||||
self.assertIn("Firefox and other compatible browsers", OPERATIONS)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
Reference in New Issue
Block a user