3.5 KiB
PDK Root Technology Migration Implementation Plan
For agentic workers: REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (
- [ ]) syntax for tracking.
Goal: Make opt_pdk_public/foundries and opt_pdk_atlas/foundries the single source of truth for both component PDK assets and technology.yml manifests, then remove the redundant mxpic/ folder from mxpic_EDA.
Architecture: The backend resolves a role-scoped PDK root from the current Flask session. Technology listing, manifest reads, project-scoped library browsing, SVG preview, and GDS export all use that same root. A directory directly under <role_pdk_root>/<foundry> is treated as a technology only when it contains technology.yml.
Tech Stack: Flask backend, local YAML manifests, PowerShell/Node static tests, mxpic_router/Nazca build path.
Task 1: Regression Tests for New PDK Source of Truth
Files:
-
Modify:
tests/layout-backend-static.test.js -
Step 1: Write the failing test
Add assertions that backend/server.py no longer defines EDA_PDK_ROOT/YML_PATH, does not reference mxpic/PDKs, lists technologies from current_pdk_root(), checks for technology.yml, and reads manifests from the active role PDK root.
- Step 2: Run test to verify it fails
Run: node tests/layout-backend-static.test.js
Expected before implementation: FAIL because the backend still scans EDA_PDK_ROOT.
Task 2: Backend Migration
Files:
-
Modify:
backend/server.py -
Step 1: Update root helpers
Remove PDK_PUBLIC_ROOT, EDA_PDK_ROOT, and YML_PATH from active path configuration. Add a helper that safely builds <current_pdk_root>/<foundry>/<technology>/technology.yml.
- Step 2: Update technology APIs
Change /api/technologies and /api/technologies/<foundry>/<technology>/manifest to use current_pdk_root(). Only return technology folders containing technology.yml.
- Step 3: Update build-time manifest lookup
Change technology_manifest_path_for_project(project) to read the project foundry/technology ID and return the manifest path under the active role PDK root.
Task 3: Documentation and Static Contract Updates
Files:
-
Modify:
README.md -
Modify:
INTRANET_DEPLOYMENT.md -
Modify:
PDK_TECHNOLOGY_XSECTION_LOADING.md -
Modify:
GDS_SVG_GENERATION_LOGIC.md -
Modify:
tests/layout-backend-static.test.js -
Step 1: Update docs
Replace old mxpic/PDKs source-of-truth language with role PDK root language.
- Step 2: Keep tests aligned
Remove assertions that require mxpic/PDKs/Silterra/.../technology.yml to exist inside mxpic_EDA.
Task 4: Remove Redundant EDA PDK Folder
Files:
-
Delete:
mxpic/ -
Step 1: Verify target path
Run: Resolve-Path mxpic and confirm it resolves inside D:\mxpic\mxpic_EDA.
- Step 2: Delete folder
Run: Remove-Item -LiteralPath D:\mxpic\mxpic_EDA\mxpic -Recurse -Force.
Task 5: Verification
Files:
-
Test:
tests/*.test.js -
Step 1: Run focused tests
Run: node tests/layout-backend-static.test.js
- Step 2: Run full static suite
Run each tests/*.test.js file with Node.
- Step 3: Check old references
Run: rg -n "EDA_PDK_ROOT|YML_PATH|mxpic/PDKs|mxpic\\\\PDKs" backend frontend tests README.md INTRANET_DEPLOYMENT.md GDS_SVG_GENERATION_LOGIC.md PDK_TECHNOLOGY_XSECTION_LOADING.md
Expected: no active-code references to the deleted internal PDK root.