-
Notifications
You must be signed in to change notification settings - Fork 71
fix: Pin duckdb <1.4.0 to avoid unhashable DuckDBPyType error #900
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
DuckDB 1.4.0 introduced a breaking change where DuckDBPyType objects are no longer hashable, causing TypeError when SQLAlchemy tries to cache result processors. This is tracked in duckdb-engine issue #1338. This pins duckdb to <1.4.0 until duckdb-engine releases a fix. Closes #809 Co-Authored-By: AJ Steers <[email protected]>
Original prompt from AJ Steers |
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
👋 Greetings, Airbyte Team Member!Here are some helpful tips and reminders for your convenience. Testing This PyAirbyte VersionYou can test this version of PyAirbyte using the following: # Run PyAirbyte CLI from this branch:
uvx --from 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1765249536-fix-duckdb-compatibility' pyairbyte --help
# Install PyAirbyte from this branch for development:
pip install 'git+https://github.com/airbytehq/PyAirbyte.git@devin/1765249536-fix-duckdb-compatibility'Helpful ResourcesPR Slash CommandsAirbyte Maintainers can execute the following slash commands on your PR:
Community SupportQuestions? Join the #pyairbyte channel in our Slack workspace. |
📝 WalkthroughWalkthroughThe duckdb dependency version constraint in Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes
Pre-merge checks and finishing touches✅ Passed checks (5 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
🧰 Additional context used🧠 Learnings (1)📚 Learning: 2024-10-10T16:17:57.989ZApplied to files:
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
🔇 Additional comments (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Pins the
duckdbdependency to<1.4.0to work around a breaking change in DuckDB 1.4.0 that causesTypeError: unhashable type: '_duckdb.typing.DuckDBPyType'when initializing DuckDB cache.This is a known upstream issue in duckdb-engine: Mause/duckdb_engine#1338
The error occurs because DuckDB 1.4.0 made
DuckDBPyTypeobjects unhashable, which breaks SQLAlchemy's result processor caching mechanism. Downgrading to DuckDB 1.3.x avoids the issue.Closes #809
Review & Testing Checklist for Human
cache = ab.get_default_cache()should not raise TypeErrorRecommended test plan: Run
python examples/run_faker.pyon Python 3.12 to verify the DuckDB cache works correctly.Notes
Requested by: AJ Steers (@aaronsteers)
Link to Devin run: https://app.devin.ai/sessions/5094f54055bd4fc68a357aa705357fce
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.