Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Django to 4.2, plus other packages #101

Merged
merged 2 commits into from
Aug 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions crawler/wpull_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,19 @@ def deactivate(self):
def init_db(self):
db_alias = "crawler"

# Django doesn't easily support dynamically adding an additional
# database once settings have been initialized. We have to manually
# define certain database options that are typically initialized
# with defaults by Django:
# https://github.com/django/django/blob/4d32ebcd57340aa8de2d6d31613f1646dc6391f6/django/db/utils.py#L159
connections.databases[db_alias] = {
"ENGINE": "django.db.backends.sqlite3",
"NAME": self.db_filename,
"AUTOCOMMIT": True,
"CONN_HEALTH_CHECKS": False,
"CONN_MAX_AGE": 0,
"OPTIONS": {},
"TIME_ZONE": None,
}

call_command("migrate", database=db_alias, app_label="crawler", run_syncdb=True)
Expand Down
22 changes: 11 additions & 11 deletions requirements/base.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
beautifulsoup4==4.12.2
click==8.0.4
cssselect==1.1.0
Django==3.2.25
django-click==2.3.0
django-debug-toolbar==3.2.4
django-filter==21.1
django-modelcluster==5.3
djangorestframework==3.15.1
djangorestframework-csv==2.1.1
whitenoise==5.3.0
beautifulsoup4==4.12.3
click==8.1.7
cssselect==1.2.0
Django==4.2.15
django-click==2.4.0
django-debug-toolbar==4.4.6
django-filter==24.3
django-modelcluster==6.3
djangorestframework==3.15.2
djangorestframework-csv==3.0.0
whitenoise==6.7.0

# Ensure libxml2 is loaded dynamically; see
# https://html5-parser.readthedocs.io/en/latest/#unix
Expand Down
2 changes: 1 addition & 1 deletion requirements/gunicorn.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
gunicorn==20.1.0
gunicorn==23.0.0
2 changes: 1 addition & 1 deletion requirements/test.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
black
coverage==6.4.3
coverage==7.6.1
Loading