Skip to content

Fix the Vercel build: keep internal imports out of the function file - #12

Merged
samjay8 merged 1 commit into
mainfrom
fix/vercel-internal-imports
Oct 25, 2026
Merged

samjay8 merged 1 commit into
mainfrom
fix/vercel-internal-imports

Conversation

@samjay8

@samjay8 samjay8 commented Oct 25, 2026

Copy link
Copy Markdown
Contributor

The first production deploy from #11 failed. Vercel compiles api/exnode.go as a package outside this module, and Go refuses that package's imports of internal/:

exnode.go:18:2: use of internal package github.com/Externalize-Labs/externalize-node/internal/archive not allowed

The server construction moves to a public package, hosted, which can import internal/. The function file now imports only hosted, and its tests move with it.

Checked

  • go vet, go test ./..., and golangci-lint (0 issues).
  • A preview deployment of this branch builds. Through it, the bundle for mainnet ledger 65,130,600 with transaction 6e8d3346… is byte-identical to a locally built one, and externalize verify accepts it: 30 validators, all 10 tier-1 organizations.

Vercel compiles api/exnode.go as a package outside this module, and Go
refuses its imports of internal/ packages, so the first deploy failed. The
server construction moves to package hosted, which may import internal/;
the function file now imports only hosted. Verified on a preview
deployment: a mainnet bundle served by it is byte-identical to a locally
built one and verifies against all ten tier-1 organizations.

Also ignore .vercel, the CLI's local project link.
@samjay8
samjay8 merged commit fe56a9f into main Oct 25, 2026
8 checks passed
@samjay8
samjay8 deleted the fix/vercel-internal-imports branch October 25, 2026 23:06
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