Skip to content

build(deps): allow deprecated 3 - #2126

Open
itzzdev09 wants to merge 1 commit into
commitizen-tools:masterfrom
itzzdev09:allow-deprecated-3
Open

itzzdev09 wants to merge 1 commit into
commitizen-tools:masterfrom
itzzdev09:allow-deprecated-3

Conversation

@itzzdev09

@itzzdev09 itzzdev09 commented Nov 22, 2026 •

Copy link
Copy Markdown

Description

pyproject.toml caps deprecated at <2. Deprecated 3.0.0 was released on 26 Sep (there is no 2.x), so commitizen can't be installed next to packages that require it. This raises the cap to <4 (deprecated (>=1.2.13, <4)); uv.lock changes only in the requires-dist specifier and uv lock --check passes.

commitizen only uses @deprecated on changelog.get_smart_tag_range. Deprecated 3.0 keeps that API; it drops Python < 3.12 (pip keeps 3.10/3.11 on 1.3.x) and removes deprecated.__date__ / deprecated.classic.string_types, which aren't used here.

Checklist

Was generative AI tooling used to co-author this PR?

  • Yes (please specify the tool below)

Generated-by: Claude Code following the guidelines

Code Changes

  • Add test cases to all the changes you introduce
  • Run uv run poe all locally to ensure this change passes linter check and tests
  • Manually test the changes:
    • Verify the feature/bug fix works as expected in real-world scenarios
    • Test edge cases and error conditions
    • Ensure backward compatibility is maintained
    • Document any manual testing steps performed
  • Update the documentation for the changes

Expected Behavior

pip install commitizen works next to deprecated>=3, and calling get_smart_tag_range still emits Call to deprecated function (or staticmethod) get_smart_tag_range. ..., so the filterwarnings entry in pyproject.toml keeps matching.

Steps to Test This Pull Request

  1. uv pip install -e . --group test "deprecated==3.0.0" on Python 3.12
  2. pytest tests

Results on Python 3.12 (Windows): 1327 passed with both Deprecated 1.3.1 and 3.0.0. The same 4 test_bump_pre_commit_changelog* tests fail on both versions on my machine (they shell out to pre-commit/prek). The deprecation warning text for get_smart_tag_range is identical on both versions.

Additional Context

Deprecated 3.0.0 changelog: https://github.com/laurent-laporte-pro/deprecated/blob/master/CHANGELOG.rst

@itzzdev09
itzzdev09 marked this pull request as ready for review November 23, 2026 05:00

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant