Skip to content

Commit 209e54c

Browse files
committed
Update ruff, fix None type annot errors
1 parent 377c85c commit 209e54c

File tree

5 files changed

+25
-26
lines changed

5 files changed

+25
-26
lines changed

course/utils.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -1224,8 +1224,7 @@ def csv_data_importable(file_contents, column_idx_list, header_count):
12241224
return True, ""
12251225

12261226

1227-
def will_use_masked_profile_for_email(
1228-
recipient_email: None | str | list[str]) -> bool:
1227+
def will_use_masked_profile_for_email(recipient_email: str | list[str] | None) -> bool:
12291228
if not recipient_email:
12301229
return False
12311230
if not isinstance(recipient_email, list):

poetry.lock

+20-20
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

prairietest/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def has_access_to_exam(
129129
exam_uuid: str,
130130
now: datetime,
131131
ip_address: IPv4Address | IPv6Address
132-
) -> None | AllowEvent:
132+
) -> AllowEvent | None:
133133
facility_id_to_most_recent_allow_event: dict[int, AllowEvent] = {}
134134
for allow_event in AllowEvent.objects.filter(
135135
facility__course=course,

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ urllib3 = "^1.26.19,<2"
125125

126126
[tool.poetry.dev-dependencies]
127127
factory_boy = "^3.3.1"
128-
ruff = "^0.7.3"
128+
ruff = "^0.7.4"
129129

130130
django-stubs = { version ="5.1.*", extras = ["compatible-mypy"] }
131131

relate/settings.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -269,9 +269,9 @@
269269
# {{{ app defaults
270270

271271
RELATE_FACILITIES: (
272-
None
273-
| dict[str, dict[str, Any]]
272+
dict[str, dict[str, Any]]
274273
| Callable[..., dict[str, dict[str, Any]]]
274+
| None
275275
) = {}
276276

277277
RELATE_TICKET_MINUTES_VALID_AFTER_USE = 0

0 commit comments

Comments
 (0)