You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 899ab89
Browse filesBrowse the repository at this point in the historyBrowse files
chore: remove dead code, slop, over tests and comment noise before open source (#400)
## Problem
Before open source, a review of the SDK, framework and CLI packages
(`packages/*`) found 737 cleanup issues of four kinds:
```
over tests 322 tests of repo tooling, tests for tests, duplicate tests
slop 241 needless defensive code, copies of helpers, pass-through wrappers, test-only seams
over comments 113 bug-fix history, essays, stale line references, comments that repeat the code
dead code 61 unused exports, branches, params, files
```
This PR removes them. It does not fix bugs or change behavior. The real
bugs from the same review go in separate PRs.
## What this PR changes
```
packages/* 620 files +22.9k −63.1k (net −40k lines)
├─ tests +15.3k −43.7k
└─ source +7.6k −19.5k
737 issues ──► 555 fixed
117 partly fixed (the safe part only)
56 skipped (public API, behavior change, or needs a new public export)
9 left for an owner decision
```
Larger items:
```
provision.ts 4,975 → 3,224 lines. A 440-line Proxy-safe redaction for a path that production
never used is now a small helper.
client.ts 2,479 → 1,918 lines. About 55 endpoints share one private request helper.
installer phases 11 get/set accessor pairs → one run-state object
config readers duplicate Wrangler config readers and record guards → shared internal ones
tooling tests 10 SDK test files that tested repo scripts or test config → removed.
vp run check now typechecks root test/ and .github/scripts instead.
```
## Decisions
| Topic | Decision |
| --- | --- |
| Behavior | No reachable change. Return values, thrown errors and
messages, CLI output, exit codes, files written and network calls stay
the same. |
| Path patterns | `@void/edge` matches header, revalidate and routing
patterns with a small parser instead of a RegExp built from the pattern.
Results stay the same for every pattern the old code could run. Patterns
too large for V8 now match instead of failing, and catastrophic
backtracking is gone. |
| User-visible text | Kept as it is on main, even where the wording is
out of date (for example `void.json`, "Wrangler"). Wording changes need
their own PRs. |
| Public API | Every published export and documented feature stays. The
generated Pages client entry still exports `router`. |
| Deleted tests | Each one either tested tooling or config, or another
test still asserts the same behavior. Unique assertions moved into the
kept test. |
| Shared helpers | Only internal modules. No new public exports, and no
`packages/*` import from `platform/`. |
## Rollout
```
main ── #399 (Cloudflare e2e fixes) ── this PR (cleanup)
```
Stacked on #399, because both PRs touch the same installer and deploy
files. Merge #399 first.
## Known limits
- In one middle commit the typecheck fails until a later commit
(`test(cli): pass explicit access ...`). This matters only for bisect,
because the PR is squash-merged.
- Independent review rounds found 35 places where the cleanup changed
behavior or lost unique coverage. All 35 are restored here.
- The removed tooling tests leave three scripts without tests:
`.github/scripts/production-baseline.ts`,
`.github/scripts/schema-compat-tests.ts` (CI only) and
`packages/platform/scripts/source-revision.mjs` (build time, display
only).
## Testing
| Check | Result |
| --- | --- |
| `vp run build:all` + `node test/check-playground-build-artifacts.mjs`
| pass |
| `vp run check` (31 typecheck tasks) | pass |
| `vp lint`, `vp fmt --check .` | pass (2,477 files formatted) |
| `vp test run` (full suite) | 685 files, 12,942 tests pass (1 file, 30
tests skipped) |
| `vp run test --base <previous head>` (latest restores) | 13 files, 497
tests pass |
| Restored tests | Each one fails when its code is broken on purpose |
🤖 Generated with [Claude Code](https://claude.com/claude-code)
https://claude.ai/code/session_0123r5HnanmW2VUrZ7VWDufH
---------
Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
0 commit comments