Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/distribution.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
# same inputs as duckdb-acl's - for the two platforms a platform node runs on, linux_amd64 and linux_arm64. Nothing
# else is built: no macOS, Windows or WASM artifact of hugr_node exists (duckdb-acl, the open node, keeps its matrix).
#
# Like duckdb-acl's, it builds against the 2.0 LINE (`duckdb_version: v2.0-cyanoptera`, the branch head) rather than
# our submodule pin - the early warning for drift, before the pin follows.
# Like duckdb-acl's, it builds against the release, `duckdb_version: v2.0.0` (spec 016; the 2.0 line's head until the
# tag), as community-extensions builds for 2.0.0.
name: Distribution build

on:
Expand All @@ -25,7 +25,7 @@ jobs:
uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@main
with:
extension_name: hugr_node
duckdb_version: v2.0-cyanoptera
duckdb_version: v2.0.0
ci_tools_version: main
# linux_amd64 and linux_arm64 only (the musl legs and windows_arm64 are opt-in, so not built either)
exclude_archs: 'osx_amd64;osx_arm64;windows_amd64;windows_amd64_mingw;wasm_mvp;wasm_eh;wasm_threads'
Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ VCPKG_TOOLCHAIN_PATH ?= $(PROJ_DIR)vcpkg/scripts/buildsystems/vcpkg.cmake
# (spec 026) found it. hugr_node builds duckdb from the pinned source, as they do.
override DUCKDB_PREBUILT_LIBRARY :=
override DUCKDB_PREBUILT_EXTENSIONS :=
# Spec 016: the pin is duckdb's v2.0.0 tag, and duckdb 2.0 no longer reads `git describe` - a build is
# v2.0.0-dev<commits>, its extensions' folder the commit, unless the version is given. Given here, the node and the
# extensions of its release are v2.0.0: what DuckDB's own repositories serve, and what kista mirrors. Bump with the pin.
export DUCKDB_VERSION ?= v2.0.0
include extension-ci-tools/makefiles/duckdb_extension.Makefile

# --- the platform part's C++ test (duckdb-acl's style: one program per test/cpp/test_*.cpp, linked against the
Expand Down
2 changes: 1 addition & 1 deletion docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# Built by the release workflow on each platform's own runner from that platform's assets
# (scripts/release_assets.sh); the build context is the assets directory:
# docker build -f docker/Dockerfile --build-arg VERSION=<tag> --build-arg REVISION=<sha> \
# --build-arg DUCKDB_VERSION=<source id> <assets dir>
# --build-arg DUCKDB_VERSION=<the release manifest's duckdb_version: v2.0.0> <assets dir>
#
# ubuntu:24.04 is the glibc the binary was built against (the ubuntu-24.04 runners). tini is PID 1: it forwards
# SIGTERM, so a node stopped during its bootstrap ends at once (its own handler serves only once the doors are open)
Expand Down
2 changes: 1 addition & 1 deletion duckdb
Submodule duckdb updated 118 files
10 changes: 5 additions & 5 deletions scripts/publish_to_kista.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ for file in "$@"; do
meta="$(python3 "$HERE/ext_footer.py" "$file")"
name="$(field "$meta" name)"
version="$(field "$meta" duckdb_version)"
case "$version" in
v*) echo "publish_to_kista: $file is built for the release $version - register it with its C API version by hand" >&2
exit 1 ;;
esac
# a release's builds (vX.Y.Z) are kista's release kind, a commit's its dev kind; a CPP build is served under its
# exact version, so it needs no C API maximum
kind=dev
case "$version" in v[0-9]*.[0-9]*.[0-9]*) kind=release ;; esac
if ! ka version list | grep -qw -- "$version"; then
ka version add "$version" -kind dev >/dev/null
ka version add "$version" -kind "$kind" >/dev/null
fi
if ! ka channel versions "$CHANNEL" | grep -qx -- "$version"; then
ka channel versions "$CHANNEL" -add "$version" >/dev/null
Expand Down
53 changes: 53 additions & 0 deletions specs/016-pin-duckdb-v2.0.0/spec.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Spec 016: re-pin duckdb to the v2.0.0 tag - the node is v2.0.0

- **Status**: implemented
- **Date**: 2026-10-21
- **Author**: the agent, at the owner's ask ("да можно сделать перепин всю семью")

DuckDB v2.0.0 was released on 2026-10-21. hugr_node builds duckdb-acl, tresor and acl-otel in, so the four move the same
day:

| submodule | from | to | why |
| --- | --- | --- | --- |
| duckdb | f8f3f4d | d54cbbe | the v2.0.0 tag (duckdb-acl spec 141, #250) |
| duckdb-acl | 8d0c1d9 | 41ec046 | spec 141: the tag; quack f96420e, ducklake 417a911 - the release's own pins |
| tresor | d7f2a1e | 036180c | its spec 038 (#67), `ACL_COMMIT` 41ec046 |
| acl-otel | 8542cad | 3916552 | its spec 027 (#56), `ACL_BASE` 41ec046 |
| extension-ci-tools | 39ffc46 | fe955ed | main's head, as duckdb-acl's |

- **The node is v2.0.0, not a commit.** duckdb 2.0 no longer reads `git describe`. A build is `v2.0.0-dev<commits>`
and names its extensions' folder by the commit, unless the version is given (duckdb-acl spec 141). The Makefile
gives it: `DUCKDB_VERSION ?= v2.0.0`, bumped with the pin.
- The node's duckdb, its release's extensions and the image label `dev.hugr.duckdb.version` are then v2.0.0.
- A node installs from a repository that serves v2.0.0. kista can mirror DuckDB's own repositories for it, which
publish nothing for a development build.
- Locally, CI and in the release build alike: the release used `make` without it and shipped `f8f3f4dcd9`.
- **`scripts/publish_to_kista.sh` takes a release.** A `vX.Y.Z` version is kista's `release` kind, a commit's its
`dev` kind. It used to refuse a release ("register it with its C API version by hand"). A CPP build is served under
its exact version, so it needs no C API maximum.
- **The distribution builds the tag**: `duckdb_version: v2.0.0`.
- **The hugr type's copy of quack's client** (spec 011) follows duckdb-acl's quack, f96420e. duckdb applies no patches
to quack since v2.0.0, so `src/hugr_type/sync.py` copies it as it is (with ours), as duckdb-acl's sync does. It
refused a pin without duckdb patches before - found by this PR's CI. The copied files are unchanged but their
banner.
- **The release's extensions** follow duckdb-acl's pins (spec 008): postgres_scanner c0f5a3c, ducklake 417a911, mssql
7e1bb1c (until its own re-pin, #511, merges).
- **Nothing in `src/` changes.**

## Testing

On the new pins (macOS), `HUGR_NODE_E2E=1 HUGR_NODE_RELEASE=1`:

- the build, and the version it names;
- `test/sql/*`, `make test-cpp`;
- `make test-e2e`: tresor in the cluster, acl_otel in hugr_node, a node bootstraps itself, the federation.

Run on macOS, all green:

- the build: `library_version` v2.0.0 at d54cbbe3df; the release's extensions' footers name v2.0.0 (postgres_scanner
c0f5a3c, CPP);
- `test/sql/*`: 982 assertions in 13 files; test-cpp: 4;
- test-e2e, all PASS: tresor in the cluster, acl_otel in hugr_node, a node bootstraps itself (its postgres_scanner
published to kista as `v2.0.0`, the release kind), the hugr type across processes and its identity through tresor.

On the PR: CI, the release's dry run (the image's e2e, now with a v2.0.0 channel) and the distribution build.
2 changes: 1 addition & 1 deletion src/hugr_type/hugr_client.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
#include "duckdb/catalog/catalog_transaction.hpp"
Expand Down
2 changes: 1 addition & 1 deletion src/hugr_type/hugr_client_affinity.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
#include "hugr_client_affinity.hpp"
Expand Down
2 changes: 1 addition & 1 deletion src/hugr_type/hugr_client_fetch_ahead.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
#include "hugr_client_fetch_ahead.hpp"
Expand Down
2 changes: 1 addition & 1 deletion src/hugr_type/include/hugr_client.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
#pragma once
Expand Down
2 changes: 1 addition & 1 deletion src/hugr_type/include/hugr_client_affinity.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
//===----------------------------------------------------------------------===//
Expand Down
2 changes: 1 addition & 1 deletion src/hugr_type/include/hugr_client_fetch_ahead.hpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (e7a9be3) - do not edit.
// GENERATED by src/hugr_type/sync.py from duckdb-acl's third_party/quack (f96420e) - do not edit.
// The `hugr` type's copy of quack's client transport (spec 011): names *Quack* -> Hugr*, the settings it
// reads quack_* -> hugr_*; every other string as quack wrote it.
#pragma once
Expand Down
18 changes: 14 additions & 4 deletions src/hugr_type/sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,10 @@
ROOT = pathlib.Path(__file__).resolve().parents[2]
ACL = ROOT / "duckdb-acl"
QUACK = ACL / "third_party" / "quack"
# duckdb's patches for quack: hugr-node's duckdb's, which must be duckdb-acl's pin (checked in main())
# duckdb's patches for quack: hugr-node's duckdb's, which must be duckdb-acl's pin (checked in main()); applied only
# when duckdb's own quack.cmake applies them (v2.0.0's carries none, as duckdb-acl's sync reads it, its spec 141)
DUCKDB_PATCHES = ROOT / "duckdb" / ".github" / "patches" / "extensions" / "quack"
DUCKDB_QUACK_CONFIG = ROOT / "duckdb" / ".github" / "config" / "extensions" / "quack.cmake"
OUR_PATCHES = ROOT / "src" / "hugr_type" / "patches"
OUT = ROOT / "src" / "hugr_type"

Expand Down Expand Up @@ -202,9 +204,17 @@ def patched_source(commit):
scratch = pathlib.Path(tempfile.mkdtemp(prefix="hugr-type-sync-"))
shutil.copytree(QUACK / "src", scratch / "src")
duckdb_patches = sorted(DUCKDB_PATCHES.glob("*.patch"))
if not duckdb_patches:
# a copy made without them would compile against the wrong duckdb and pass the sync
sys.exit(f"sync: no quack patches under {DUCKDB_PATCHES} - is duckdb-acl's duckdb checked out?")
if not DUCKDB_QUACK_CONFIG.exists():
sys.exit(f"sync: no {DUCKDB_QUACK_CONFIG} - is hugr-node's duckdb checked out?")
if "APPLY_PATCHES" in DUCKDB_QUACK_CONFIG.read_text():
if not duckdb_patches:
# a copy made without them would compile against the wrong duckdb and pass the sync
sys.exit(f"sync: duckdb's quack.cmake applies patches, and none are under {DUCKDB_PATCHES}")
else:
# duckdb builds this quack as it is: so do the copies, and a patch left in duckdb's tree is not applied
if duckdb_patches:
sys.exit(f"sync: duckdb's quack.cmake applies no patches, yet {DUCKDB_PATCHES} holds some")
print("duckdb carries no patches for this quack: its src as it is, with ours")
for patch in duckdb_patches + sorted(OUR_PATCHES.glob("*.patch")):
targets = re.findall(r"^\+\+\+ b/(\S+)", patch.read_text(), flags=re.M)
if targets and not any(t.startswith("src/") for t in targets):
Expand Down