packaging: single-source the integrations extra via self-reference#145
Conversation
The integrations optional-dependency group re-listed the exact pins of the dagster/airflow/dbt extras, so a version bump in one of those could silently drift from integrations. Reference them instead (freshdata-cleaner[...]). Hatchling flattens the self-reference at build time, so the emitted Requires-Dist is byte-identical to the previous inline union -- no change to the install closure. twine check and tests/test_packaging.py pass.
|
Strix is installed on this repository, but we couldn't run this PR security review because this workspace's trial has ended. Add a card to resume code reviews here. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe ChangesIntegrations dependency declaration
Estimated code review effort: 1 (Trivial) | ~2 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
What
Rewrite the
integrationsoptional-dependency group as a self-referentialextra so its orchestration pins are single-sourced:
Previously it re-listed the exact pins already declared in the
dagster,airflow, anddbtextras, so bumping a version in one of those couldsilently drift from
integrations.Why it's safe — install closure is unchanged
Hatchling flattens the self-reference at build time. The
Requires-Distemitted into the built metadata is byte-identical to the previous inline union:
The de-dupe lives only in the
pyproject.tomlsource; nothing downstream seesa change.
Validation
python -m build --sdist→ PKG-INFORequires-Distidentical to prior uniontwine check→ PASSEDtests/test_packaging.py→ PASSEDfreshdata-cleanerdistribution and the three referenced extras exist
Metadata-only change: no source touched, so ruff/mypy/pytest results are
unchanged from
main.Provenance and scope
Surfaced by an over-engineering audit pass (AI tooling assisted). The audit
raised two other candidates that were deliberately not acted on:
flightextra — flagged as a redundant alias ofpyarrow. It is not:StreamingCleaner.clean_arrow_flightis a real, tested public method and itsImportError instructs users to
pip install 'freshdata-cleaner[flight]'.It's a semantically distinct install target, kept as-is.
ai_copilotprovider hook — a deliberate (experimental) extension seam,not dead scaffolding. Left intact.
This PR contains only the one change that is both a genuine de-dup and fully
backward-compatible.
Summary by CodeRabbit