Skip to content

Commit f52b028

Browse files
committed
Lint fixes
1 parent 9250853 commit f52b028

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

scripts/gen_pages.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
full_doc_path = Path(nav_pages_path, doc_path)
3636

3737
# Handle edge cases
38-
parts = (src_dir,) + tuple(module_path.parts)
38+
parts = (src_dir, *tuple(module_path.parts))
3939
if parts[-1] == "__init__":
4040
parts = parts[:-1]
4141
doc_path = doc_path.with_name("index.md")

tests/conftest.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import inspect
22
from contextlib import _AsyncGeneratorContextManager, asynccontextmanager
3-
from typing import Tuple, Type, Union
3+
from typing import ClassVar, Tuple, Type, Union
44
from uuid import uuid4
55

66
import pytest
@@ -107,7 +107,7 @@ class ParentModel(sa_bind.declarative_base):
107107
# required in order to access columns with server defaults
108108
# or SQL expression defaults, subsequent to a flush, without
109109
# triggering an expired load
110-
__mapper_args__ = {"eager_defaults": True}
110+
__mapper_args__: ClassVar = {"eager_defaults": True}
111111

112112
model_id = Column(Integer, primary_key=True, autoincrement=True)
113113
name = Column(String)
@@ -124,7 +124,7 @@ class ChildModel(sa_bind.declarative_base):
124124
# required in order to access columns with server defaults
125125
# or SQL expression defaults, subsequent to a flush, without
126126
# triggering an expired load
127-
__mapper_args__ = {"eager_defaults": True}
127+
__mapper_args__: ClassVar = {"eager_defaults": True}
128128

129129
model_id = Column(Integer, primary_key=True, autoincrement=True)
130130
parent_model_id = Column(

tests/repository/test_composite_pk.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from typing import Type
1+
from typing import ClassVar, Type
22

33
import pytest
44
from sqlalchemy import Column, Integer, String
@@ -31,7 +31,7 @@ class MyModel(default_bind.declarative_base):
3131
# required in order to access columns with server defaults
3232
# or SQL expression defaults, subsequent to a flush, without
3333
# triggering an expired load
34-
__mapper_args__ = {"eager_defaults": True}
34+
__mapper_args__: ClassVar = {"eager_defaults": True}
3535

3636
model_id = Column(Integer, primary_key=True)
3737
model_other_id = Column(Integer, primary_key=True)

0 commit comments

Comments
 (0)