Skip to content

fix: correct dashboard packaging for npm publish#1702

Merged
OneStepAt4time merged 2 commits intodevelopfrom
fix/1699-dashboard-packaging
Apr 12, 2026
Merged

fix: correct dashboard packaging for npm publish#1702
OneStepAt4time merged 2 commits intodevelopfrom
fix/1699-dashboard-packaging

Conversation

@OneStepAt4time
Copy link
Copy Markdown
Owner

Summary

Fix the dashboard 404 error in the published npm package (#1691). The root cause was \dashboard/dist\ in \package.json#files\ creating a wrong-path duplicate in the tarball, plus insufficient validation in the copy script.

Changes

  • *\package.json* — Remove \dashboard/dist\ from \ iles\ array. The dashboard is already copied to \dist/dashboard/\ by the build script; including \dashboard/dist\ caused a duplicate at the wrong path.
  • *\scripts/copy-dashboard.mjs* — Add post-copy validation (checks \dist/dashboard/index.html\ exists) and CI-aware error handling (hard fail if dashboard missing during publish).
  • *\src/server.ts* — Improve dashboard availability check: validate \index.html\ presence instead of just the directory, with actionable hint in the warning log.

Testing


  • px tsc --noEmit\ — clean

  • pm run build\ — passes

  • pm test\ — 158 passed, 0 failed (2801 tests total)

Aegis version

Developed with: v0.3.2-alpha

Closes #1699
Fixes #1691

@OneStepAt4time OneStepAt4time added this to the v0.5.1-alpha milestone Apr 12, 2026
- Remove 'dashboard/dist' from package.json files array to prevent
  wrong-path duplicate in npm tarball
- Add post-copy validation in copy-dashboard.mjs (checks index.html)
- Add CI-aware error handling: hard fail if dashboard missing in CI
- Improve server.ts dashboard check to validate index.html presence

Closes #1699
Fixes #1691
@OneStepAt4time OneStepAt4time force-pushed the fix/1699-dashboard-packaging branch from 4693d38 to eff78f7 Compare April 12, 2026 12:39
@OneStepAt4time OneStepAt4time merged commit bc215bf into develop Apr 12, 2026
10 checks passed
@OneStepAt4time OneStepAt4time deleted the fix/1699-dashboard-packaging branch April 12, 2026 12:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant