do not require workalendar dependency (#46348)

This commit is contained in:
Thomas NOËL 2020-09-04 11:46:55 +02:00
parent 48fd832353
commit 137c136a80
2 changed files with 9 additions and 5 deletions

View File

@ -171,9 +171,13 @@ REQUESTS_PROXIES = None
# we use 28s by default: timeout just before web server, which is usually 30s
REQUESTS_TIMEOUT = 28
EXCEPTIONS_SOURCES = {
'holidays': {'class': 'workalendar.europe.France', 'label': _('Holidays')},
}
try:
import workalendar
EXCEPTIONS_SOURCES = {
'holidays': {'class': 'workalendar.europe.France', 'label': _('Holidays')},
}
except ImportError:
EXCEPTIONS_SOURCES = {}
TEMPLATE_VARS = {}

4
debian/control vendored
View File

@ -24,10 +24,10 @@ Depends: ${misc:Depends},
python3-psycopg2,
python3-django-mellon,
python3-dateutil,
python3-workalendar,
uwsgi,
uwsgi-plugin-python3
Recommends: nginx
Recommends: nginx,
python3-workalendar
Suggests: postgresql
Breaks: python-chrono (<<0.84.post6)
Replaces: python-chrono (<<0.84.post6)