@viccydev/pi-fpa 0.9.6 → 0.9.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -159,12 +159,12 @@ pi list
159
159
  团队分发建议使用固定 Git tag:
160
160
 
161
161
  ```bash
162
- pi install git:github.com/linyqh/pi-fpa@v0.9.6
162
+ pi install git:github.com/linyqh/pi-fpa@v0.9.8
163
163
  ```
164
164
 
165
165
  ## 发布到 npm
166
166
 
167
- 发布动作由 GitHub Release 触发。Release 标签必须严格使用 `v<package.json version>`,例如版本 `0.9.6` 对应 `v0.9.6`。工作流会检出该标签,执行 `npm ci`、`npm test` 和包内容预检,全部通过后发布公开包 `@viccydev/pi-fpa`。普通 Release 发布到 `latest`,Prerelease 发布到 `next`。
167
+ 发布动作由 GitHub Release 触发。Release 标签必须严格使用 `v<package.json version>`,例如版本 `0.9.8` 对应 `v0.9.8`。工作流会检出该标签,执行 `npm ci`、`npm test` 和包内容预检,全部通过后发布公开包 `@viccydev/pi-fpa`。普通 Release 发布到 `latest`,Prerelease 发布到 `next`。
168
168
 
169
169
  发布认证使用 npm Trusted Publishing / OIDC,不使用长期 npm Token。npm 包后台的 Trusted Publisher 配置为:
170
170
 
@@ -62,7 +62,12 @@ async function selectWorkspaceProject(root) {
62
62
  const canonicalRoot = await realpath(root);
63
63
  const entries = await readdir(canonicalRoot, { withFileTypes: true });
64
64
  for (const entry of entries.sort((left, right) => left.name.localeCompare(right.name))) {
65
- if (!entry.isDirectory() || entry.isSymbolicLink() || entry.name === ".fpa-dashboard") continue;
65
+ // Skip every dot-directory, not just the dashboard's. A workspace also
66
+ // holds data directories the product owns (.fpa-finance, and whatever
67
+ // comes next), and they sort before real project names — excluding them
68
+ // one name at a time means the next one silently becomes "the project"
69
+ // and the real one stops being refreshed.
70
+ if (!entry.isDirectory() || entry.isSymbolicLink() || entry.name.startsWith(".")) continue;
66
71
  const project = await realpath(resolve(canonicalRoot, entry.name));
67
72
  if (dirname(project) === canonicalRoot) return project;
68
73
  }
@@ -246,7 +246,13 @@ export async function projectCalibration(options: CalibrationOptions = {}): Prom
246
246
  ...(coverage !== null
247
247
  ? { progress: { fraction: Math.max(0, Math.min(1, coverage)), label: percent(coverage, locale) ?? "—", tone: (coverage >= 0.99 ? "positive" : "warning") as "positive" | "warning" } }
248
248
  : {}),
249
- footnote: coverage !== null && coverage < 0.99 ? "其余为未归因残差,已在瀑布图中单列" : undefined,
249
+ // Spread rather than assign undefined: the module is fingerprinted
250
+ // with stableJson, which walks every own key and rejects
251
+ // undefined. JSON.stringify would have silently dropped it, so
252
+ // this only fails at publish time, not at projection time.
253
+ ...(coverage !== null && coverage < 0.99
254
+ ? { footnote: "其余为未归因残差,已在瀑布图中单列" }
255
+ : {}),
250
256
  },
251
257
  },
252
258
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@viccydev/pi-fpa",
3
- "version": "0.9.6",
3
+ "version": "0.9.8",
4
4
  "type": "module",
5
5
  "description": "Full-cycle FP&A planning, strategy, forecast, and review prompts, skills, and data tools for Pi",
6
6
  "license": "UNLICENSED",
@@ -34,9 +34,9 @@
34
34
  "fpa-dashboard-worker": "./bin/fpa-dashboard-worker.mjs"
35
35
  },
36
36
  "scripts": {
37
- "test": "node tests/package-structure.test.mjs && node tests/workflow-routing.test.mjs && node --test tests/workflow-routing-guard.test.mjs tests/graph-contract.test.mjs tests/graph-installer.test.mjs && node tests/extension-unit.test.mjs && node --test tests/catalog-timeout.test.mjs tests/artifact-store.test.mjs tests/artifact-ledger.test.mjs tests/artifact-handoff.test.mjs tests/forecast-compose.test.mjs tests/forecast-finalize.test.mjs tests/dashboard-actuals.test.mjs tests/dashboard-projector.test.mjs tests/dashboard-module-publisher.test.mjs tests/dashboard-stage-projector.test.mjs tests/strategy-decision.test.mjs tests/decision-ledger.test.mjs tests/csv-source.test.mjs tests/finance-projector.test.mjs tests/calibration-projector.test.mjs tests/compat-publisher-split.test.mjs tests/cycle-operating-projection.test.mjs tests/forward-outlook.test.mjs tests/forecast-accuracy.test.mjs tests/dashboard-publisher.test.mjs tests/dashboard-provenance.test.mjs tests/dashboard-coordinator.test.mjs && node tests/pi-loader-smoke.mjs && node tests/worker-loader-smoke.mjs && node tests/publish-workflow.test.mjs",
37
+ "test": "node tests/package-structure.test.mjs && node tests/workflow-routing.test.mjs && node --test tests/workflow-routing-guard.test.mjs tests/graph-contract.test.mjs tests/graph-installer.test.mjs && node tests/extension-unit.test.mjs && node --test tests/catalog-timeout.test.mjs tests/artifact-store.test.mjs tests/artifact-ledger.test.mjs tests/artifact-handoff.test.mjs tests/forecast-compose.test.mjs tests/forecast-finalize.test.mjs tests/dashboard-actuals.test.mjs tests/dashboard-projector.test.mjs tests/dashboard-module-publisher.test.mjs tests/dashboard-stage-projector.test.mjs tests/strategy-decision.test.mjs tests/decision-ledger.test.mjs tests/csv-source.test.mjs tests/finance-projector.test.mjs tests/calibration-projector.test.mjs tests/compat-publisher-split.test.mjs tests/module-publishable.test.mjs tests/cycle-operating-projection.test.mjs tests/forward-outlook.test.mjs tests/forecast-accuracy.test.mjs tests/dashboard-publisher.test.mjs tests/dashboard-provenance.test.mjs tests/dashboard-coordinator.test.mjs && node tests/pi-loader-smoke.mjs && node tests/worker-loader-smoke.mjs && node tests/publish-workflow.test.mjs",
38
38
  "test:structure": "node tests/package-structure.test.mjs",
39
- "test:unit": "node tests/extension-unit.test.mjs && node --test tests/catalog-timeout.test.mjs tests/artifact-store.test.mjs tests/artifact-ledger.test.mjs tests/artifact-handoff.test.mjs tests/forecast-compose.test.mjs tests/forecast-finalize.test.mjs tests/dashboard-actuals.test.mjs tests/dashboard-projector.test.mjs tests/dashboard-module-publisher.test.mjs tests/dashboard-stage-projector.test.mjs tests/strategy-decision.test.mjs tests/decision-ledger.test.mjs tests/csv-source.test.mjs tests/finance-projector.test.mjs tests/calibration-projector.test.mjs tests/compat-publisher-split.test.mjs tests/cycle-operating-projection.test.mjs tests/forward-outlook.test.mjs tests/forecast-accuracy.test.mjs tests/dashboard-publisher.test.mjs tests/dashboard-provenance.test.mjs tests/dashboard-coordinator.test.mjs",
39
+ "test:unit": "node tests/extension-unit.test.mjs && node --test tests/catalog-timeout.test.mjs tests/artifact-store.test.mjs tests/artifact-ledger.test.mjs tests/artifact-handoff.test.mjs tests/forecast-compose.test.mjs tests/forecast-finalize.test.mjs tests/dashboard-actuals.test.mjs tests/dashboard-projector.test.mjs tests/dashboard-module-publisher.test.mjs tests/dashboard-stage-projector.test.mjs tests/strategy-decision.test.mjs tests/decision-ledger.test.mjs tests/csv-source.test.mjs tests/finance-projector.test.mjs tests/calibration-projector.test.mjs tests/compat-publisher-split.test.mjs tests/module-publishable.test.mjs tests/cycle-operating-projection.test.mjs tests/forward-outlook.test.mjs tests/forecast-accuracy.test.mjs tests/dashboard-publisher.test.mjs tests/dashboard-provenance.test.mjs tests/dashboard-coordinator.test.mjs",
40
40
  "test:loader": "node tests/pi-loader-smoke.mjs && node tests/worker-loader-smoke.mjs",
41
41
  "test:live": "node tests/live-smoke.mjs",
42
42
  "pack:check": "npm pack --dry-run"