Skip to content

feat: bundle PostHog ducklake fork (v1.0-posthog.1)#556

Merged
bill-ph merged 3 commits intomainfrom
claude/quirky-lederberg-a8de21
May 9, 2026
Merged

feat: bundle PostHog ducklake fork (v1.0-posthog.1)#556
bill-ph merged 3 commits intomainfrom
claude/quirky-lederberg-a8de21

Conversation

@bill-ph
Copy link
Copy Markdown
Collaborator

@bill-ph bill-ph commented May 9, 2026

Summary

  • Swap the bundled ducklake.duckdb_extension in both Dockerfile and Dockerfile.worker from the upstream extensions.duckdb.org build to PostHog's fork at https://github.com/PostHog/ducklake/releases/tag/v1.0-posthog.1. Mirrors the existing httpfs override pattern (benben/duckdb-httpfs fork). Tag is parameterised via --build-arg DUCKLAKE_EXTENSION_TAG=... for future bumps.
  • Add ducklake.duckdb_extension to shouldRefreshBundledExtension so the cached copy on a long-lived data-dir PVC is replaced when the image ships an updated fork build — same rationale as postgres_scanner (the previous symptom was stale cached extensions silently outlasting image upgrades).

The runtime path is unchanged: bootstrapBundledExtensions seeds <data-dir>/extensions/v1.5.2/linux_<arch>/, the DSN already sets allow_unsigned_extensions=true, and INSTALL ducklake; LOAD ducklake (server.go:1217) finds the pre-seeded binary without a network fetch.

Test plan

  • go build ./...
  • go test ./server -run 'BundledExtensions|SeedBundled' — added TestSeedBundledExtensionsRefreshesDucklake covering the new refresh-allowlist behaviour.
  • CI: image build downloads the fork's ducklake-linux-{amd64,arm64}.duckdb_extension assets (verified to exist on the release).
  • Smoke test in dev: spin up a fresh worker, LOAD ducklake; succeeds, and SELECT * FROM duckdb_extensions() WHERE extension_name='ducklake' shows the fork's extension binary loaded from the local cache.
  • Confirm fork is built against the DuckDB 1.5.2 extension ABI — otherwise LOAD will fail with a version mismatch (same failure mode called out in Dockerfile.worker:18-23).

🤖 Generated with Claude Code

bill-ph and others added 3 commits May 9, 2026 10:05
Switches the ducklake extension shipped in the duckgres and
duckgres-worker images from the upstream extensions.duckdb.org build to
PostHog's fork at https://github.com/PostHog/ducklake/releases. Mirrors
the existing httpfs override pattern.

Also adds ducklake.duckdb_extension to shouldRefreshBundledExtension so
the cached copy on a long-lived data-dir PVC is replaced when the image
ships a newer fork build — same rationale as postgres_scanner.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Already covered by TestSeedBundledExtensionsReplacesExistingFilesWithUpdatedContents
exercising the same code path via postgres_scanner.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
After bundling the v1.0-posthog.1 fork in Dockerfile.worker, add a kind-
cluster integration test that queries duckdb_extensions().extension_version
on a worker and asserts it matches the fork's commit short SHA (90dc1f24)
rather than the upstream build's. The expected value lives next to the
test with a comment pointing at DUCKLAKE_EXTENSION_TAG in the Dockerfiles
so the two move together.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@bill-ph bill-ph merged commit 2acc015 into main May 9, 2026
22 checks passed
@bill-ph bill-ph deleted the claude/quirky-lederberg-a8de21 branch May 9, 2026 15:36
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