Skip to content

Fix staging table strategy#249

Merged
krinart merged 2 commits into
trunkfrom
viktor/fix-lakebase
May 22, 2026
Merged

Fix staging table strategy#249
krinart merged 2 commits into
trunkfrom
viktor/fix-lakebase

Conversation

@krinart
Copy link
Copy Markdown
Contributor

@krinart krinart commented May 16, 2026

🗣 Description

Got broken in #243

The staging table strategy strips primary keys from dataset configs to prevent Cayenne's upsert-on-conflict behavior from conflicting with MERGE-based updates. However, the stripping happened before setup() was called, so the system adapter also received empty PKs — breaking Lakebase's create_synced_table API which requires at least one primary key column.

Fix: clone datasets before stripping so setup gets the original PKs, while the ETL pipeline still gets the stripped version.

Verified in https://github.com/spiceai/spicebench/actions/runs/25971199591

@krinart krinart self-assigned this May 16, 2026
@krinart krinart added the bug Something isn't working label May 16, 2026
@krinart krinart enabled auto-merge (squash) May 19, 2026 22:58
@krinart krinart merged commit fa00844 into trunk May 22, 2026
11 checks passed
@krinart krinart deleted the viktor/fix-lakebase branch May 22, 2026 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants