Matrix App Debugging
SkillDev toolsDebug Matrix OS app failures including needs_build responses, missing dist bundles, broken matrix.json manifests, icon 404s, console errors, and integration proxy issues.
Available today. Use it from your connected AI after setup.
No other account needed.
Connect ahel once, and every AI you use reads what you have installed.
Then ask your AI: use the Matrix App Debugging skill
What this skill tells your AI
The instructions your AI receives, as published by hamedmp/matrix-os in skills/matrix/debug-app/SKILL.md and read by ahel’s review.
When to Use
Use this when a Matrix app shows an error, blank screen, needs_build, missing icons, CORS failures, or console errors.
First Checks
cd ~/apps/<slug>
test -f matrix.json
test -f package.json
test -f dist/index.html
If dist/index.html is missing, build the app:
pnpm install --prefer-offline
pnpm build
test -f dist/index.html
needs_build
{"error":"needs_build","status":"needs_build"} means the gateway found a Vite app manifest but no usable build output.
Fix:
- Check
matrix.jsonhasruntime: "vite"andbuild.output: "dist". - Run
pnpm install --prefer-offline. - Run
pnpm build. - Verify
dist/index.html. - Reload the app window.
Manifest Checks
Good baseline:
{
"name": "Whiteboard",
"slug": "whiteboard",
"description": "Collaborative drawing and notes",
"version": "1.0.0",
"runtime": "vite",
"runtimeVersion": "^1.0.0",
"listingTrust": "first_party",
"category": "productivity",
"icon": "whiteboard",
"build": {
"command": "pnpm build",
"output": "dist"
}
}
Avoid stale fields from old app formats such as type: "html-app" or type: "react-app" unless the current gateway explicitly supports them.
Console Error Triage
needs_build: build output is missing.404 /icons/<slug>.png: default icon asset missing or manifest points at a non-existent icon.404 app bundle:entryor Vitebaseis wrong.CORSfrom provider API: app is calling a provider directly. Use Matrix integration routes.SecurityErrorfromlocalStorage: app code is running inside the Matrix sandbox. Persist throughwindow.MatrixOS.db; keep localStorage fallback code test-only/no-op.- Missing or undefined saved fields: check
matrix.jsonstorage.tablesdeclares the column and type. 401 /api/auth/ws-token: user is not authenticated or the route is being called from the wrong shell context.Clerk failed to load clerk.example.com: stale environment or image build used placeholder Clerk config.
Icon Fixes
- Use committed default icon assets for built-in apps.
- Manifest
iconshould be a slug, not an arbitrary URL. - Verify the resolved icon path exists in Matrix's system icons.
- For games, prefer the shipped
game-centerasset unless the app has its own committed icon. - Do not rely on runtime image generation for default icons.
Data Bridge Checks
- Confirm
window.MatrixOS?.dbexists before debugging state as an app bug. - Check the manifest declares every table and persisted column used by the app.
- Reproduce create/update/delete failures and verify the UI rolls optimistic state back after bridge errors.
- For ordered lists, best scores, timers, histories, and stats, look for racing writes. Serialize dependent updates or use a single bridge operation when possible.
- Avoid treating a test-only localStorage guard as production persistence. The shell sandbox should use the bridge path.
Integration Errors
Customer VPSes should proxy integration requests to platform. If /api/integrations returns 404:
- Check gateway env has internal platform URL/token.
- Check platform has Pipedream credentials.
- Do not copy Pipedream secrets into the customer VPS as a workaround.
Verification
Before saying fixed:
cd ~/apps/<slug>
pnpm build
test -f dist/index.html
Then reload the app and confirm:
- The app renders.
- Browser console has no app errors.
- Network tab has no bundle 404s.
- Any integration calls go through Matrix routes.
Signals
- GitHub stars
- 64
- Forks
- 20
- Last commit
- Sep 2026
Advanced
- Catalog kind
- skill
- Gateway key
matrix-debug-app- Source
- github.com/hamedmp/matrix-os