Modernize packaging: migrate setup.py to PEP 621 pyproject.toml#645
Merged
axellpadilla merged 7 commits intoMay 20, 2026
Merged
Conversation
- Replace setup.py with pyproject.toml (setuptools backend), reading version dynamically from dbt/adapters/sqlserver/__version__.py. - Restore pyodbc>=4.0.35,<5.2.0 as a direct dependency. It was previously pulled in transitively via dbt-fabric; that dep was dropped in 1.9.1rc1 but the runtime `import pyodbc` was not, leaving fresh installs broken. - Move azure-identity to an `azure` extra. The code already guards azure imports with try/except ModuleNotFoundError, so this makes the optionality first-class: pip install dbt-sqlserver[azure]. - Move dev tooling to a `dev` extra; retire dev_requirements.txt. Use pip install -e .[dev]. - Drop MANIFEST.in in favor of [tool.setuptools.package-data]. - Ship dbt/adapters/sqlserver/py.typed. - requires-python = ">=3.10"; drop the Python 3.9 classifier (3.9 reached EOL in October 2025). - Update unit/integration/release workflows + Makefile accordingly. The release workflow now uses `python -m build` and an inline tag/version match instead of `python setup.py sdist bdist_wheel` and the old VerifyVersionCommand.
Collaborator
|
@joshmarkovic I migrated this to uv, thats why you have conflicts, PEP 621 + 735. |
Resolved conflicts by adopting PEP 735 [dependency-groups] for dev tooling, matching the uv migration on master: - workflows + Makefile + devcontainer install via `uv pip install [--system] -e . --group dev` - pyproject.toml: dev moved out of [project.optional-dependencies] into [dependency-groups]; azure stays an extra - release workflow: inline tag/version verify replaced with .github/scripts/verify_version.py so it can be tested and run through pre-commit - integration-tests path filters: dropped removed files (dev_requirements.txt, setup.py, setup.cfg, MANIFEST.in) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
for more information, see https://pre-commit.ci
Resolve setup.py conflict by keeping deletion (replaced by pyproject.toml). Upstream's pyodbc>=5.2.0 bump is preserved in our optional [pyodbc] extra. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
axellpadilla
approved these changes
May 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
import pyodbcwas not, leaving fresh installs broken.azureextra. The code already guards azure imports with try/except ModuleNotFoundError, so this makes the optionality first-class: pip install dbt-sqlserver[azure].devextra; retire dev_requirements.txt. Use pip install -e .[dev].python -m buildand an inline tag/version match instead ofpython setup.py sdist bdist_wheeland the old VerifyVersionCommand.