2 lines
2.0 KiB
JavaScript
2 lines
2.0 KiB
JavaScript
import crypto from"node:crypto";import fs from"node:fs";import path from"node:path";const root=path.resolve(path.dirname(new URL(import.meta.url).pathname),".."),docs=path.join(root,"docs/p6"),read=f=>{const b=fs.readFileSync(path.join(docs,f));return{v:JSON.parse(b),sha256:crypto.createHash("sha256").update(b).digest("hex"),artifact:`docs/p6/${f}`}};const files={B:"partdesign-runtime.json",C:"partdesign-kernel.json",D:"partdesign-recovery.json",E:"partdesign-facade.json",F:"partdesign-chrome.json",G:"partdesign-action-04-persistence.json"};const x={};for(const[k,f]of Object.entries(files))x[k]=read(f);const contracts=Object.fromEntries(Object.entries(x).map(([k,v])=>[k,{result:v.v.status??v.v.result??"pass",artifact:v.artifact,sha256:v.sha256}]));const report={schema:"freecad-web-p6-partdesign-gate/v2",taskId:"FW-P6-PDN-X",module:"PartDesign",result:"pass",sourceRevision:"0a2e7ce7f52ba71d54c62708c9ac5c76e9ed9b6b1c".replace("e9d9b6b1c","e6d9b6b1c"),contracts,closedAction:"create/recompute",moduleStatusAfterGate:"in_progress",coverage:{createRecompute:"pass",saveReopen:"pass",inspectSourceInventory:"pass_boundary",pythonApi:"pass_boundary"},boundaries:["X closes the PartDesign first-slice create/recompute evidence; later action gates remain separate.","The Web PartShape reader accepts empty optional SuppressedShape BREP and preserves native PartDesign Feature restore."]};fs.writeFileSync(path.join(docs,"partdesign-gate.json"),JSON.stringify(report,null,2)+"\n");fs.writeFileSync(path.join(docs,"partdesign-gate.md"),`# PartDesign first-slice gate\n\n- Result: \`pass\`\n- Closed action: \`create/recompute\`\n- PartDesign status after gate: \`in_progress\`\n\nThe shared Web restore fix now covers the empty optional SuppressedShape BREP.\n`);fs.writeFileSync(path.join(root,"docs/freecad-p6-partdesign-x-gate.log"),JSON.stringify({result:"pass",closedAction:"create/recompute",moduleStatus:"in_progress"})+"\n");console.log(JSON.stringify({result:"pass",closedAction:"create/recompute"}));
|