Skip to content

packaging: single-source the integrations extra via self-reference#145

Merged
JohnnyWilson16 merged 1 commit into
mainfrom
chore/dedupe-integrations-extra-jwd
Jul 16, 2026
Merged

packaging: single-source the integrations extra via self-reference#145
JohnnyWilson16 merged 1 commit into
mainfrom
chore/dedupe-integrations-extra-jwd

Conversation

@JohnnyWilson16

@JohnnyWilson16 JohnnyWilson16 commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

What

Rewrite the integrations optional-dependency group as a self-referential
extra so its orchestration pins are single-sourced:

integrations = ["freshdata-cleaner[dagster,airflow,dbt]"]

Previously it re-listed the exact pins already declared in the dagster,
airflow, and dbt extras, so bumping a version in one of those could
silently drift from integrations.

Why it's safe — install closure is unchanged

Hatchling flattens the self-reference at build time. The Requires-Dist
emitted into the built metadata is byte-identical to the previous inline union:

Requires-Dist: apache-airflow>=2.6.0; extra == "integrations"
Requires-Dist: dagster>=1.5.0; extra == "integrations"
Requires-Dist: dbt-core>=1.5.0; extra == "integrations"
Requires-Dist: sqlalchemy>=1.4; extra == "integrations"

The de-dupe lives only in the pyproject.toml source; nothing downstream sees
a change.

Validation

  • python -m build --sdist → PKG-INFO Requires-Dist identical to prior union
  • twine check → PASSED
  • tests/test_packaging.py → PASSED
  • PEP 508 parse of the self-ref confirms it targets the freshdata-cleaner
    distribution 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:

  • flight extra — flagged as a redundant alias of pyarrow. It is not:
    StreamingCleaner.clean_arrow_flight is a real, tested public method and its
    ImportError instructs users to pip install 'freshdata-cleaner[flight]'.
    It's a semantically distinct install target, kept as-is.
  • ai_copilot provider 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

  • Chores
    • Consolidated integration dependency configuration into a single shared extra.
    • Updated dependency documentation to reflect centralized version management.

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-security

Copy link
Copy Markdown
Contributor

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.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 9b69ee4e-1a08-4a36-b328-25586771467e

📥 Commits

Reviewing files that changed from the base of the PR and between ef24bab and 9473990.

📒 Files selected for processing (1)
  • pyproject.toml

📝 Walkthrough

Walkthrough

The integrations optional dependency group in pyproject.toml now references freshdata-cleaner[dagster,airflow,dbt] instead of explicitly listing integration dependencies and version constraints.

Changes

Integrations dependency declaration

Layer / File(s) Summary
Consolidate integration dependencies
pyproject.toml
The integrations extra now references the consolidated freshdata-cleaner extras, and the surrounding comments describe the single-sourced version approach.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: johnnywilson-portfolio, jyothiswaroop000

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the change and validation, but it omits the required template sections for issue linkage, change type, and checklist. Add the template sections: Description, Fixes #, Type of Change, and Checklist items, or fill them out explicitly.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the packaging change to the integrations extra via self-reference.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/dedupe-integrations-extra-jwd

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@JohnnyWilson16
JohnnyWilson16 merged commit 161c666 into main Jul 16, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant