Add ADBC driver support for unified database connectivity#52
Conversation
Implement ADBC (Arrow Database Connectivity) adapter enabling connection to multiple databases through the DBC driver manager. Supports PostgreSQL, MySQL, Snowflake, BigQuery, SQLite, and other ADBC-compatible databases. - New ADBCAdapter class with DB-API compatible interface - Support for adbc:// URL scheme and YAML dict-style configs - Automatic cursor lifecycle management to prevent resource leaks - Hierarchical fallback for metadata retrieval (native -> information_schema) - SQL injection prevention via identifier validation - Optional dependency group for adbc-driver-manager and pyarrow - 25 comprehensive tests including DBC driver integration
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9d91f7eb56
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| # Parse query parameters | ||
| params = parse_qs(parsed.query) | ||
|
|
||
| # Extract uri if provided | ||
| uri = params.pop("uri", [None])[0] |
There was a problem hiding this comment.
Parse adbc://driver/uri path for connection URI
The new ADBC URL parser only pulls the connection URI from the query string (params.pop("uri", ...)) and never uses parsed.path. As a result, the documented format adbc://driver/uri (see SemanticLayer docstring) will drop the URI entirely and attempt to connect without it (or default :memory: for sqlite), which will fail for drivers that require a URI. This is a regression for users following the newly documented example; consider extracting parsed.path as the URI when present or supporting both path and ?uri= formats.
Useful? React with 👍 / 👎.
Support adbc://driver/uri format in addition to adbc://driver?uri=... This fixes a regression where the documented path format would drop the URI entirely and fail for drivers requiring a connection URI.
Summary
Implement ADBC (Arrow Database Connectivity) adapter enabling connection to multiple databases through the DBC driver manager. Supports PostgreSQL, MySQL, Snowflake, BigQuery, SQLite, and other ADBC-compatible databases via unified interface.
Changes
Testing