Phase 3a-PR-D of internal#77 (task #235). Completes the cross-repo
composition migration started by PR #5 (sibling-clone+symlink) and
the platform-side !external resolver shipped in molecule-core#105.
CHANGES
- org.yaml: replace
- !include dev-lead/workspace.yaml
with
- !external
repo: molecule-ai/molecule-dev-department
ref: main
path: dev-lead/workspace.yaml
Composition is now platform-side: at POST /org/import time the
workspace-server fetches molecule-ai/molecule-dev-department at
ref=main into <orgBaseDir>/.external-cache/, grafts the dev-lead
subtree, and rewrites every files_dir to be cache-prefixed.
- dev-lead symlink deleted. The post-suspension sibling-clone deploy
contract (operator must keep both repos as siblings under
/org-templates/) is no longer required. The platform fetches the
subtree on demand.
- .gitignore: add .external-cache/ entry. Operators see the cache
populate during imports; we don't track it.
DEPLOYMENT IMPACT
Operators running molecule-core PR #105 or later can import this
template without operator-side molecule-dev-department clone
(task #230 becomes obsolete). Operators running an older platform
binary will see import fail with 'unknown !external tag' — visible
error, not silent breakage.
To pin a specific tag/SHA for production stability, change ref: main
to e.g. ref: v1.0.0 (currently no tags published; landing this
unlocks the option).
VERSIONING
No DB schema change. No public API change. Pure org-template
composition shape change. Existing imports of older snapshots of
this template still work — !include + symlink were never the only
composition mechanism, and operators who have the symlink can
re-add it locally if they need to roll back.
VERIFIED LOCALLY 2026-05-08
--- PASS: TestPRD_MigratedParentTemplateImports (0.55s)
post-migration parent resolves to 39 workspaces
(5 PM-tree + 6 Marketing-tree + 28 dev-tree, fetched from
molecule-ai/molecule-dev-department@main via the production
gitFetcher into .external-cache/).
FOLLOW-UP TASKS
- Update molecule-dev-department's local-e2e-setup.sh to drop the
symlink check (now that parent template doesn't ship one).
- Decide fate of TestLocalE2E_DevDepartmentExtraction +
TestLocalE2E_FilesDirConsumption (they tested the symlink-based
composition; now skip gracefully because no template uses that
shape — keep as opt-in regression coverage).
- Tag molecule-ai/molecule-dev-department v1.0.0 + pin ref here.
Refs:
internal#77 — extraction RFC (Phase 3a phasing in comment 1995)
molecule-core#105 — !external resolver
molecule-core#106 — !external integration + e2e tests
task #235 (PR-D)
task #230 — obsolete after this PR
Hongming GO 2026-05-08 ('do PR-B/C/D')