diegosouzapw
0231fbb335
build(verify): close ralph-loop-1 gaps — align tests + fix stale .next/app refs
...
- tests/unit/build-next-isolated.test.ts: align to .build/next distDir + removed
app-snapshot transient entry (was RED 4/7 -> 7/7); legitimate alignment to the
intentional Layer-1 behavior change, not masking.
- scripts/dev/run-next-playwright.mjs: testDistDir() default .next -> .build/next
(E2E start runner found the standalone at the wrong path).
- prepublish.ts: stale log 'app/docs/' -> 'dist/docs/'.
- electron/README.md: '.next/standalone' -> '.build/next/standalone'.
- remove dead scripts/build/paths.mjs (created in L1, imported by nothing).
Verified: build-next-isolated 7/7, run-next-playwright 3/3, assemble 1/1, lint clean.
2026-06-03 16:06:59 -03:00
diegosouzapw
b7fdcdddf8
build(layer1): rename standalone output app/ -> dist/; delete both App-Router move hacks
...
- scripts/build/prepublish.ts: APP_DIR -> DIST_DIR; remove Step 1 and Step 2.5
hack blocks; fix MCP esbuild outfile (app/ -> dist/); update all log messages
- scripts/build/build-next-isolated.mjs: remove legacy-app-snapshot entry from
getTransientBuildPaths() (App-Router collision hack deleted)
- scripts/build/assembleStandalone.mjs: fix standalone package.json after copy —
removes "type":"module" so Next.js standalone server.js (CJS) loads correctly;
also adds .build/next/ to allowed staging prefixes so server bundles are kept
- scripts/build/pack-artifact-policy.ts: app/ -> dist/ in all PACK_ARTIFACT_* paths;
add ".build/next/" to APP_STAGING_ALLOWED_PATH_PREFIXES (Layer 1 distDir change)
- scripts/build/validate-pack-artifact.ts: dist/ check instead of app/
- scripts/build/postinstall.mjs: all app/ paths -> dist/
- scripts/build/postinstallSupport.mjs: hasStandaloneAppBundle checks dist/server.js
- bin/cli/commands/serve.mjs: APP_DIR -> dist/
- package.json: files[] "app/" -> "dist/"
- .gitignore: remove both /app and /app/ entries (no longer needed)
Smoke: NO_APP_DIR_OK; DIST_OK; check:pack-artifact PASS; health 200 from dist/
2026-06-03 14:59:20 -03:00
diegosouzapw
5b484737bb
build(layer1): isolate Next output to .build/next; gitignore .build/ dist/ .next/
...
- next.config.mjs: distDir default ".next" → ".build/next" (NEXT_DIST_DIR override kept)
- .gitignore: add /.build/, /dist/, /.next/; remove loose dist/ under #dependencies
- scripts/build/paths.mjs: new shared module exporting ROOT, DIST_DIR, STANDALONE_DIR
- scripts/build/build-next-isolated.mjs: default ".next" → ".build/next" in distDir,
resetStandaloneOutput fallback, and pruneStandaloneArtifacts
- scripts/build/prepublish.ts: NEXT_DIST default ".next" → ".build/next"
- scripts/build/assembleStandalone.mjs: legacy syncStandalone* helpers updated
to resolve distDir via NEXT_DIST_DIR || ".build/next"
- tsconfig.json: Next.js auto-added .build/next/types includes (generated on build)
Smoke: .build/next/standalone/server.js exists; BUNDLE_OK confirmed;
no .next directory created.
2026-06-03 14:04:30 -03:00
diegosouzapw
27c08178d7
build(layer0): prepublish consumes single build via assembleStandalone (drop 2nd next build)
...
prepublish.ts no longer runs npm install + a second full 'next build'; it asserts
the .next/standalone produced by 'npm run build' exists (builds once if missing) and
assembles the npm staging app/ via assembleStandalone({sanitizePaths,patchTurbopackChunks}).
All npm-unique steps kept (MITM tsc, MCP/CLI esbuild, doc/sidecar copies, mkdir data,
prune+validate). A publish now runs exactly ONE next build (was 2). Verified: 1 build,
check:pack-artifact green (6467 entries), npm pack -> fresh install -> boot -> health 200.
-211/+40 lines.
2026-06-03 13:46:37 -03:00
Hernan Javier Ardila Sanchez
fd26e601a2
fix(dashboard): use lightweight ping endpoint for MaintenanceBanner ( fixes #3040 ) ( #3043 )
...
Integrated into release/v3.8.8. Applied review fixes: moved the SELECT 1 into a pingDb() db helper (no raw SQL in route, Hard Rule #5 ) + the 503 catch no longer leaks err.message (Hard Rule #12 ). Thanks @herjarsa!
2026-06-01 14:30:17 -03:00
diegosouzapw
f3b944a55a
refactor(scripts): organize into build/dev/check/docs/i18n/ad-hoc subfolders
...
Reorganizes the 29 active scripts under scripts/ into purpose-driven
subfolders:
- scripts/build/ (11) — Build, install, publish, runtime env
- scripts/dev/ (13) — Dev servers, test runners, healthchecks
- scripts/check/ (10) — Lint/validation/coverage checks
- scripts/docs/ (2) — Docs index and provider reference generation
- scripts/i18n/ (+3) — Adds Python translation utilities (check/validate/autotranslate)
- scripts/ad-hoc/ (4) — One-shot maintenance utilities
Updates all references in package.json, electron/package.json,
.husky/pre-commit, .github/workflows/ci.yml, Dockerfile, src/,
tests/, scripts/ internal cross-imports, playwright.config.ts,
and English docs (CODEBASE_DOCUMENTATION, ENVIRONMENT, FEATURES,
RELEASE_CHECKLIST, COVERAGE_PLAN, ELECTRON_GUIDE, I18N, GEMINI).
Also patches scripts/build/pack-artifact-policy.ts so the npm pack
allowlist mirrors the new layout.
Validates with:
- npm run lint (exit 0 — pre-existing minified-bundle errors only)
- npm run typecheck:core (exit 0)
- npm run check:docs-all (exit 0)
- unit tests for moved scripts (57 tests pass)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com >
2026-05-13 10:14:25 -03:00