Skip to content

Commit

Permalink
Update requirements to fix dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
AndersSeverinsen committed Dec 22, 2024
1 parent 5b1d489 commit 41d5a0e
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 20 deletions.
5 changes: 3 additions & 2 deletions bartenders/forms.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from urllib.parse import urljoin

from captcha.fields import ReCaptchaField
from captcha.widgets import ReCaptchaV2Invisible
from django import forms
from django.conf import settings
from django.contrib.auth.models import User
Expand All @@ -15,7 +16,7 @@


class BartenderApplicationForm(forms.ModelForm):
captcha = ReCaptchaField()
captcha = ReCaptchaField(widget=ReCaptchaV2Invisible)

class Meta:
model = BartenderApplication
Expand All @@ -24,7 +25,7 @@ class Meta:
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)

self.fields["captcha"].help_text = _("Hjemmesiden er sikret med reCAPTCHA")
self.fields["captcha"].help_text = _("Hjemmesiden er sikret med reCAPTCHAv2")
self.fields["tshirt_size"].widget.attrs.update({"class": "form-control"})
for name in self.fields:
self.fields[name].required = name != "info"
Expand Down
10 changes: 7 additions & 3 deletions requirements.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
django==3.*
django>=3.2.20
python-dotenv
djangorestframework
dj-config-url
Expand All @@ -11,7 +11,7 @@ whitenoise
django-ical
django-object-actions
django-extensions
ipython
ipython>=8.10.0
requests-html
django-logentry-admin
django-cors-headers
Expand All @@ -21,10 +21,14 @@ iterfzf
celery[redis]
django-celery-beat
django-rosetta==0.9.9
lxml_html_clean
lxml_html_clean>=0.4.0
django_bootstrap_icons==0.8.7
sorl-thumbnail==12.10
django-dprog-jfu
django-versatileimagefield
django-model-utils
Unidecode
urllib3>=1.26.19
Pygments>=2.15.0
sqlparse>=0.5.0
tqdm>=4.66.3
53 changes: 40 additions & 13 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile with Python 3.13
# This file is autogenerated by pip-compile with Python 3.8
# by the following command:
#
# pip-compile requirements.in
Expand All @@ -14,8 +14,16 @@ appnope==0.1.4
# via ipython
asgiref==3.8.1
# via django
asttokens==3.0.0
# via stack-data
async-timeout==5.0.1
# via redis
backcall==0.2.0
# via ipython
backports-zoneinfo[tzdata]==0.2.1
# via
# celery
# kombu
beautifulsoup4==4.9.3
# via
# bs4
Expand Down Expand Up @@ -54,7 +62,7 @@ defusedxml==0.7.1
# via django-bootstrap-icons
dj-config-url==0.1.1
# via -r requirements.in
django==3.2.4
django==3.2.25
# via
# -r requirements.in
# django-bootstrap-datepicker-plus
Expand Down Expand Up @@ -111,6 +119,8 @@ django-versatileimagefield==3.1
# via -r requirements.in
djangorestframework==3.12.4
# via -r requirements.in
executing==2.1.0
# via stack-data
fake-useragent==0.1.11
# via requests-html
gunicorn==20.1.0
Expand All @@ -121,7 +131,7 @@ idna==2.10
# via requests
importlib-metadata==8.5.0
# via pyppeteer
ipython==7.24.1
ipython==8.12.3
# via -r requirements.in
ipython-genutils==0.2.0
# via traitlets
Expand All @@ -135,7 +145,7 @@ lxml==5.2.1
# via
# lxml-html-clean
# pyquery
lxml-html-clean==0.1.1
lxml-html-clean==0.4.1
# via -r requirements.in
matplotlib-inline==0.1.2
# via ipython
Expand All @@ -153,22 +163,26 @@ pillow==10.4.0
# django-versatileimagefield
polib==1.2.0
# via django-rosetta
prompt-toolkit==3.0.18
prompt-toolkit==3.0.48
# via
# click-repl
# ipython
psycopg2==2.9.9
# via -r requirements.in
ptyprocess==0.7.0
# via pexpect
pure-eval==0.2.3
# via stack-data
pydantic==2.9.2
# via django-bootstrap-datepicker-plus
pydantic-core==2.23.4
# via pydantic
pyee==11.1.1
# via pyppeteer
pygments==2.9.0
# via ipython
pygments==2.18.0
# via
# -r requirements.in
# ipython
pyppeteer==2.0.0
# via requests-html
pyquery==1.4.3
Expand Down Expand Up @@ -209,26 +223,39 @@ sorl-thumbnail==12.10.0
# via -r requirements.in
soupsieve==2.2.1
# via beautifulsoup4
sqlparse==0.4.1
# via django
tqdm==4.61.1
# via pyppeteer
sqlparse==0.5.3
# via
# -r requirements.in
# django
stack-data==0.6.3
# via ipython
tqdm==4.67.1
# via
# -r requirements.in
# pyppeteer
traitlets==5.0.5
# via
# ipython
# matplotlib-inline
typing-extensions==4.12.2
# via
# annotated-types
# asgiref
# django-bootstrap-datepicker-plus
# ipython
# kombu
# pydantic
# pydantic-core
# pyee
tzdata==2024.1
# via celery
# via
# backports-zoneinfo
# celery
unidecode==1.3.8
# via -r requirements.in
urllib3==1.26.5
urllib3==1.26.20
# via
# -r requirements.in
# pyppeteer
# requests
vine==5.1.0
Expand Down
5 changes: 3 additions & 2 deletions udlejning/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

from bootstrap_datepicker_plus.widgets import DateTimePickerInput
from captcha.fields import ReCaptchaField
from captcha.widgets import ReCaptchaV2Invisible
from django import forms
from django.conf import settings
from django.urls import reverse
Expand All @@ -14,7 +15,7 @@


class UdlejningApplicationForm(forms.ModelForm):
captcha = ReCaptchaField()
captcha = ReCaptchaField(widget=ReCaptchaV2Invisible)

class Meta:
model = UdlejningApplication
Expand All @@ -27,7 +28,7 @@ class Meta:
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)

self.fields["captcha"].help_text = _("Hjemmesiden er sikret med reCAPTCHA")
self.fields["captcha"].help_text = _("Hjemmesiden er sikret med reCAPTCHAv2")
self.fields["paymentType"].widget.attrs.update({"class": "form-control"})
for name in self.fields:
self.fields[name].required = name not in ["EANnumber", "comments"]
Expand Down

0 comments on commit 41d5a0e

Please sign in to comment.