Skip to content

Conversation

@Flix6x
Copy link
Collaborator

@Flix6x Flix6x commented Jan 24, 2025

This PR removes the pin on pydantic 2.81.

The pydantic~=2.8.2 requirement from #40 is not compatible with Home Assistant 2025.1, which runs on pydantic==2.10. Generally, libraries should try to set only minimum requirements, unless an actual issue with a higher dependency has been identified.

Inline, next to any dependency constraint, we should try to state the reason for the constraint or even better, cross-reference a GH Issue, so it has a chance of getting resolved later.

Footnotes

  1. Test ran with 2.10.6:

    default: freeze> python -m pip freeze --all
    default: annotated-types==0.7.0,astroid==3.3.8,click==8.1.8,coverage==7.6.10,dill==0.3.9,iniconfig==2.0.0,isort==5.13.2,mccabe==0.7.0,mypy==1.14.1,mypy-extensions==1.0.0,packaging==24.2,pip==24.3.1,platformdirs==4.3.6,pluggy==1.5.0,pydantic==2.10.6,pydantic_core==2.27.2,pylint==3.3.3,pytest==8.3.4,pytest-cov==6.0.0,pytest-cover==3.0.0,pytest-coverage==0.0,pytest-timer==1.0.0,pytz==2024.2,s2-python @ file:///home/runner/work/s2-python/s2-python/dist/s2_python-0.4.0-py3-none-any.whl#sha256=8a6297cf4506dea70740db54e8f49d1ed806dbec08cc4fe743ba5e89b32b549d,tomlkit==0.13.2,types-pytz==2024.2.0.20241221,typing_extensions==4.12.2,websockets==13.1
    

@Flix6x Flix6x self-assigned this Jan 24, 2025
@Flix6x Flix6x requested a review from victorgarcia98 January 24, 2025 09:56
@Flix6x Flix6x marked this pull request as ready for review January 24, 2025 09:56
Signed-off-by: F.N. Claessen <[email protected]>
@Flix6x Flix6x merged commit 0a6a34d into main Jan 24, 2025
19 checks passed
@Flix6x Flix6x deleted the fix/remove-pydantic-maximum-requirement branch January 24, 2025 10:01
@Flix6x
Copy link
Collaborator Author

Flix6x commented Jan 24, 2025

@lfse-slafleur Did you have a particular reason for setting pydantic==2.8.2 as the minimum? If so, I can add it as an inline comment. If not, I assume it was just the latest at the time you updated to pydantic 2, and therefore, a reasonable minimum.

@lfse-slafleur
Copy link
Member

@lfse-slafleur Did you have a particular reason for setting pydantic==2.8.2 as the minimum? If so, I can add it as an inline comment. If not, I assume it was just the latest at the time you updated to pydantic 2, and therefore, a reasonable minimum.

@Flix6x None other than I might a mistake. I intended pydantic ~= 2.8 to allow for any minor version updates.

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.

4 participants