Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PydanticImportError #24

Closed
maxboettinger opened this issue Oct 2, 2023 · 2 comments
Closed

PydanticImportError #24

maxboettinger opened this issue Oct 2, 2023 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@maxboettinger
Copy link

Hi Jochen,

whilst trying to run your awesome package I came across a breaking error, probably because of a new dependency version of pydantic.
I found this happening in a clean anaconda environment for both python 3.10 and 3.11 when running any command.

This is the error I get:

Traceback (most recent call last): File "/Users/max/.local/bin/kptncook", line 5, in <module> from kptncook import cli File "/Users/max/.local/pipx/venvs/kptncook/lib/python3.11/site-packages/kptncook/__init__.py", line 16, in <module> from .api import KptnCookClient, parse_id File "/Users/max/.local/pipx/venvs/kptncook/lib/python3.11/site-packages/kptncook/api.py", line 8, in <module> from .config import settings File "/Users/max/.local/pipx/venvs/kptncook/lib/python3.11/site-packages/kptncook/config.py", line 7, in <module> from pydantic import ( File "/Users/max/.local/pipx/venvs/kptncook/lib/python3.11/site-packages/pydantic/__init__.py", line 218, in __getattr__ return _getattr_migration(attr_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/max/.local/pipx/venvs/kptncook/lib/python3.11/site-packages/pydantic/_migration.py", line 294, in wrapper raise PydanticImportError( pydantic.errors.PydanticImportError: BaseSettings has been moved to the pydantic-settings package. See https://docs.pydantic.dev/2.4/migration/#basesettings-has-moved-to-pydantic-settings for more details. For further information visit https://errors.pydantic.dev/2.4/u/import-error

I would really appreciate you looking into this.

Thanks in advance! :)

@ephes
Copy link
Owner

ephes commented Oct 5, 2023

Hi Max,

just saw your issue. Thanks for reporting this 😃. It's probably caused by pydantic 2 incompatibilities and I didn't want to put an upper limit to the pydantic version. I'll look into this soon.

ephes added a commit that referenced this issue Oct 5, 2023
ephes added a commit that referenced this issue Oct 5, 2023
ephes added a commit that referenced this issue Oct 5, 2023
@ephes
Copy link
Owner

ephes commented Oct 5, 2023

Should be fixed by now.

@ephes ephes self-assigned this Oct 5, 2023
@ephes ephes added the bug Something isn't working label Oct 5, 2023
@ephes ephes closed this as completed Oct 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants