Skip to content

Commit dbd62ae

Browse files
committed
fix 3.8
1 parent a42f98a commit dbd62ae

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

src/view/config.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
from __future__ import annotations
2-
from ipaddress import IPv4Address
3-
from pathlib import Path
4-
from typing import Any, Literal, Union
2+
53
import importlib.util
64
import sys
5+
from ipaddress import IPv4Address
6+
from pathlib import Path
7+
from typing import Any, Dict, Literal, Union
8+
79
from configzen import ConfigField, ConfigModel
810

911

@@ -18,7 +20,7 @@ class ServerConfig(ConfigModel):
1820
host: IPv4Address = IPv4Address("0.0.0.0")
1921
port: int = 5000
2022
backend: Literal["uvicorn"] = "uvicorn"
21-
extra_args: dict[str, Any] = ConfigField(default_factory=dict)
23+
extra_args: Dict[str, Any] = ConfigField(default_factory=dict)
2224

2325

2426
class LogConfig(ConfigModel):

src/view/routing.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import re
55
from dataclasses import dataclass, field
66
from enum import Enum
7-
from typing import Any, Callable, Generic, TypeVar, Union
7+
from typing import Any, Callable, Generic, Type, TypeVar, Union
88

99
from typing_extensions import ParamSpec
1010

@@ -248,7 +248,7 @@ class _NoDefault:
248248
...
249249

250250

251-
_NoDefaultType = type[_NoDefault]
251+
_NoDefaultType = Type[_NoDefault]
252252

253253

254254
def query(

0 commit comments

Comments
 (0)