Skip to content

Commit f86a7b8

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 6d64544 commit f86a7b8

File tree

6 files changed

+20
-13
lines changed

6 files changed

+20
-13
lines changed

config/urls.py

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
1. Import the include() function: from django.urls import include, path
1515
2. Add a URL to urlpatterns: path('blog/', include('blog.urls'))
1616
"""
17+
1718
from django.conf import settings
1819
from django.conf.urls.static import static
1920
from django.contrib import admin

lwmdb/management/commands/createfixtures.py

+7-3
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,13 @@ def handle(self, *args, **kwargs):
5151
)
5252

5353
# Block if non-allowed apps passed
54-
exit(
55-
f"App(s) not allowed: {[x for x in apps if not x in ALLOWED_APPS]}",
56-
) if [x for x in apps if not x in ALLOWED_APPS] else None
54+
(
55+
exit(
56+
f"App(s) not allowed: {[x for x in apps if not x in ALLOWED_APPS]}",
57+
)
58+
if [x for x in apps if not x in ALLOWED_APPS]
59+
else None
60+
)
5761

5862
for app in apps:
5963
if app == "gazetteer":

lwmdb/management/commands/loadfixtures.py

+7-3
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,13 @@ def handle(self, *args, **kwargs):
3232
)
3333

3434
# Block if non-allowed apps passed
35-
exit(
36-
f"App(s) not allowed: {[x for x in apps if not x in ALLOWED_APPS]}",
37-
) if [x for x in apps if not x in ALLOWED_APPS] else None
35+
(
36+
exit(
37+
f"App(s) not allowed: {[x for x in apps if not x in ALLOWED_APPS]}",
38+
)
39+
if [x for x in apps if not x in ALLOWED_APPS]
40+
else None
41+
)
3842

3943
for app in apps:
4044
if app == "newspapers":

lwmdb/utils.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -662,8 +662,7 @@ def path_or_str_suffix(
662662
return suffix
663663

664664

665-
class DataSourceDownloadError(Exception):
666-
...
665+
class DataSourceDownloadError(Exception): ...
667666

668667

669668
@dataclass

mitchells/import_fixtures.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -217,9 +217,9 @@ def create_mitchells_fixtures(self):
217217
# Create mitchells_publication_for_linking (for newspapers)
218218
mitchells_publication_for_linking = mitchells_entries.copy()
219219
mitchells_publication_for_linking = mitchells_publication_for_linking[["NLP"]]
220-
mitchells_publication_for_linking[
221-
"entry"
222-
] = mitchells_publication_for_linking.index
220+
mitchells_publication_for_linking["entry"] = (
221+
mitchells_publication_for_linking.index
222+
)
223223

224224
mitchells_publication_for_linking.to_csv(
225225
AUTO_FILE_LOCATIONS["mitchells_publication_for_linking"]

newspapers/models.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -278,8 +278,7 @@ def _sync_title_counts(self, force: bool = False) -> None:
278278

279279
SAS_ENV_VARIABLE = "FULLTEXT_SAS_TOKEN"
280280

281-
class TitleLengthError(Exception):
282-
...
281+
class TitleLengthError(Exception): ...
283282

284283
@property
285284
def download_dir(self):

0 commit comments

Comments
 (0)