Skip to content

ADBC driver's adbc_ingest fails with "Schema with name memory does not exist" unless import duckdb ran first #698

Closed

Description

@edgarrmondragon

What happens?

adbc_ingest seems to require some side-effect of import duckdb to be able to execute.

Seen on 2.0.0.dev2610191843, adbc-driver-manager 1.12.0, Python 3.15. MRE attached as a PEP 723 script.

I should also mention that this happens regardless of whether the standalone driver is installed with dbc, i.e. whether duckdb shows up here

$ dbc list
DRIVER     VERSION LEVEL LOCATION

duckdb     1.5.6   user  /Users/edgarramirez/Library/Application Support/ADBC/Drivers

or not.

BTW, thanks for publishing abi3 wheels!

To Reproduce

# /// script
# requires-python = ">=3.11"
# dependencies = [
#     "duckdb==2.0.0.dev2610191843",
#     "pyarrow",
#     "adbc-driver-manager",
# ]
# ///
"""MRE: adbc_driver_duckdb fails in adbc_ingest unless `import duckdb` ran first.

Usage:
    uv run mre.py            # fails
    uv run mre.py --import   # works
"""

import sys
import tempfile
from pathlib import Path

if "--import" in sys.argv:
    import duckdb

import pyarrow as pa
from adbc_driver_duckdb import dbapi

table = pa.table({"a": [1]})

with tempfile.TemporaryDirectory() as tmp, dbapi.connect(str(Path(tmp) / "w.duckdb")) as conn:
    with conn.cursor() as cur:
        n = cur.adbc_ingest("t", table, mode="create")
    print(f"ingested {n} row(s)")

OS:

OSX

DuckDB Package Version:

2.0.0.dev2610191843

Python Version:

3.15

Full Name:

Edgar Ramírez Mondragón

Affiliation:

Meltano

What is the latest build you tested with? If possible, we recommend testing with the latest nightly build.

I have tested with a nightly build

Did you include all relevant data sets for reproducing the issue?

Yes

Did you include all code required to reproduce the issue?

  • Yes, I have

Did you include all relevant configuration to reproduce the issue?

  • Yes, I have

Activity

  1. evertlammerts commented on Oct 20, 2026

    @evertlammerts
    Member

    @edgarrmondragon thanks for the test! I can reproduce it, and the root cause is that the root extensions aren't loaded on dlopen but on module import. Should be a small fix, but there are some changes in flight that have to land first. I'll try to get this fixed today so we can ship the fix in v2.0.

  2. added a commit that references this issue on Oct 20, 2026
    a2c151f
  3. evertlammerts commented on Oct 20, 2026

    @evertlammerts
    Member

    Fixed!

  4. edgarrmondragon commented on Oct 20, 2026

    @edgarrmondragon
    Author

    Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions