Skip to content

Commit 4e73ad0

Browse files
committed
refactor: Loosen pydantic requirements
1 parent 0dea3a1 commit 4e73ad0

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

eoapi/auth_utils/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
from .auth import OpenIdConnectAuth # noqa
22
from .config import OpenIdConnectSettings # noqa
33

4-
__version__ = "0.3.0"
4+
__version__ = "0.4.0"

eoapi/auth_utils/config.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
from typing import Optional, Sequence
22

33
from pydantic import AnyHttpUrl
4-
from pydantic_settings import BaseSettings
4+
5+
try:
6+
from pydantic.v1 import BaseSettings # type:ignore
7+
except ImportError:
8+
from pydantic import BaseSettings # type:ignore
59

610

711
class OpenIdConnectSettings(BaseSettings):

pyproject.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@ authors = [
1616
]
1717
dependencies = [
1818
"cryptography>=43.0.0",
19-
"fastapi>=0.112.0",
20-
"pydantic-settings>=2.2.1",
19+
"fastapi>=0.7.0",
2120
"pyjwt>=2.9.0",
2221
]
2322
description = "Authentication & authorization helpers for eoAPI"

0 commit comments

Comments
 (0)