Skip to content

Fix storage, import maps, builds, and CLI handling - #1404

Merged
ije merged 1 commit into
mainfrom
ije/codebase-review-fixes
Sep 9, 2026
Merged

Fix storage, import maps, builds, and CLI handling#1404
ije merged 1 commit into
mainfrom
ije/codebase-review-fixes

Conversation

@ije

@ije ije commented Sep 9, 2026

Copy link
Copy Markdown
Member

Concurrent operations and failed I/O could corrupt cached files, lose import-map entries, or overwrite HTML after failed package resolution. This fixes those paths and several build, S3, and CLI errors found in the same review.

  • Publish filesystem writes and lexer downloads only after successful completion; preserve existing files on failure and close S3 response bodies reliably.
  • Follow S3 listing pagination, batch deletions with checksums, and surface per-object failures.
  • Resolve the longest import-map prefix and synchronize dependency traversal, scope creation, CLI results, and web dependency loading.
  • Preserve build arguments in declaration URLs and queue keys, reject corrupt splitting caches, and fix generated package metadata and CSS escaping.
  • Repair npm bootstrap downloads, platform names, release tags, executable permissions, and exit status handling; preserve HTML and unmanaged imports during CLI updates.
  • Remove dead code and unnecessary dependency traversal, replace version sorting with a linear scan, and avoid repeated directory-result copies.

Validation:

  • go test -race ./...
  • Staticcheck and git diff --check
  • Debug lexer installation tests
  • bun test cli/npm/bootstrap.test.mjs — 7 tests
  • Deno transform, declaration, and raw-file suites — 6 tests against an isolated local server
  • Version-resolution microbenchmark with 10,000 releases: median 3.44 ms → 2.50 ms across three runs on an Apple M4 Pro

S3 regressions use controlled HTTP responses; the credentialed live-S3 suite and full Deno suite are left to CI.

@ije
ije merged commit ccad8ee into main Sep 9, 2026
5 checks passed
@ije
ije deleted the ije/codebase-review-fixes branch September 9, 2026 20:34
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