Skip to content

Commit

Permalink
Update requirements
Browse files Browse the repository at this point in the history
Includes replacements for a deprecated arrow function.
  • Loading branch information
madprime committed Apr 16, 2020
1 parent c6149f6 commit 9bc79b1
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 62 deletions.
2 changes: 1 addition & 1 deletion open_humans/management/commands/expunge_addresses.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class Command(BaseCommand):
def handle(self, *args, **options):
self.stdout.write("Expunging addresses")

ninety_days_ago = arrow.utcnow().replace(days=-90)
ninety_days_ago = arrow.utcnow().shift(days=-90)

# remove the IP address from all logs older than 90 days
expunged_logs = NewDataFileAccessLog.objects.filter(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Command(BaseCommand):
def handle(self, *args, **options):
self.stdout.write("Expunging incomplete project data files")

expired_time = arrow.utcnow().replace(
expired_time = arrow.utcnow().shift(
hours=-settings.INCOMPLETE_FILE_EXPIRATION_HOURS
)

Expand Down
6 changes: 3 additions & 3 deletions open_humans/member_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -492,9 +492,9 @@ def form_valid(self, form):
sender = self.request.user
receiver = self.get_object().user

one_day_ago = arrow.utcnow().replace(days=-1).datetime
two_days_ago = arrow.utcnow().replace(days=-2).datetime
seven_days_ago = arrow.utcnow().replace(days=-7).datetime
one_day_ago = arrow.utcnow().shift(days=-1).datetime
two_days_ago = arrow.utcnow().shift(days=-2).datetime
seven_days_ago = arrow.utcnow().shift(days=-7).datetime

messages_last_day = EmailMetadata.objects.filter(
sender=sender, timestamp__gt=one_day_ago
Expand Down
2 changes: 1 addition & 1 deletion private_sharing/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def now_plus_24_hours():
"""
Return a datetime 24 hours in the future.
"""
return arrow.utcnow().replace(hours=+24).datetime
return arrow.utcnow().shift(hours=+24).datetime


def id_label_to_project(id_label):
Expand Down
114 changes: 58 additions & 56 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,91 +5,93 @@
# pip-compile requirements.in
#
-e git+https://github.com/beaugunderson/django-storages-s3upload.git#egg=django-storages-s3upload
amqp==2.5.0 # via kombu
amqp==2.5.2 # via kombu
ansicolors==1.1.8
arrow==0.14.2
beautifulsoup4==4.7.1
billiard==3.6.0.0 # via celery
bleach==3.1.0
boto3==1.9.165
arrow==0.15.5
beautifulsoup4==4.9.0
billiard==3.6.3.0 # via celery
bleach==3.1.4
boto3==1.12.39
boto==2.49.0
botocore==1.12.165 # via boto3, s3transfer
botocore==1.15.39 # via boto3, s3transfer
brotlipy==0.7.0
celery==4.3.0
certifi==2019.3.9 # via requests
cffi==1.12.3 # via brotlipy
certifi==2020.4.5.1 # via requests
cffi==1.14.0 # via brotlipy
chardet==3.0.4 # via requests
configparser==3.7.4 # via tini
coverage==4.5.3 # via django-coverage-plugin
configparser==5.0.0 # via tini
coverage==5.1 # via django-coverage-plugin
defusedxml==0.6.0 # via python3-openid
dj-database-url==0.5.0
django-allauth==0.39.1
django-appconf==1.0.3
django-autoslug==1.9.4
django-bootstrap-pagination==1.7.0
django-cors-headers==3.0.2
django-coverage-plugin==1.6.0
django-debug-toolbar==1.11
django-extensions==2.1.9
django-filter==2.1.0
django-allauth==0.41.0
django-appconf==1.0.4
django-autoslug==1.9.7
django-bootstrap-pagination==1.7.1
django-cors-headers==3.2.1
django-coverage-plugin==1.8.0
django-debug-toolbar==2.2
django-extensions==2.2.9
django-filter==2.2.0
django-forms-bootstrap==3.1.0
django-gulp==4.1.0
django-hash-filter2==2.0
django-heroku==0.3.1
django-ipware==2.1.0
django-oauth-toolkit==1.2.0
django-oauth-toolkit==1.3.2
django-pylibmc==0.6.1
django-recaptcha==2.0.4
django-storages==1.7.1
django-waffle==0.17.0
django-recaptcha==2.0.6
django-storages==1.9.1
django-waffle==0.20.0
django==2.2.10
djangorestframework==3.9.4
djangorestframework==3.11.0
docopt==0.4.0 # via mailchimp
docutils==0.14 # via botocore
docutils==0.15.2 # via botocore
env-tools==2.2.0
factory-boy==2.12.0
faker==1.0.7 # via factory-boy
faker==4.0.3 # via factory-boy
feedparser==5.2.1
gevent==1.4.0
gevent==1.5.0
greenlet==0.4.15 # via gevent
gunicorn==19.9.0
idna==2.8 # via requests
jinja2==2.10.1
jmespath==0.9.4 # via boto3, botocore
jsonfield==2.0.2
kombu==4.6.1 # via celery
gunicorn==20.0.4
idna==2.9 # via requests
importlib-metadata==1.6.0 # via kombu
jinja2==2.11.2
jmespath==0.9.5 # via boto3, botocore
jsonfield==3.1.0
kombu==4.6.8 # via celery
mailchimp==2.0.9
markdown==3.1.1
markdown==3.2.1
markupsafe==1.1.1 # via jinja2
mock==3.0.5
oauthlib==3.0.1 # via django-oauth-toolkit, requests-oauthlib
pillow==6.2.0
psutil==5.6.3 # via django-gulp
psycopg2==2.8.2 # via django-heroku
pycparser==2.19 # via cffi
mock==4.0.2
oauthlib==3.1.0 # via django-oauth-toolkit, requests-oauthlib
pillow==7.1.1
psutil==5.7.0 # via django-gulp
psycopg2==2.8.5 # via django-heroku
pycparser==2.20 # via cffi
pylibmc==1.5.2
pyparsing==2.4.0
python-dateutil==2.8.0 # via arrow, botocore, faker
pyparsing==2.4.7
python-dateutil==2.8.1 # via arrow, botocore, faker
python-magic==0.4.15
python3-openid==3.1.0 # via django-allauth
pytz==2019.1 # via celery, django
pytz==2019.3 # via celery, django
raven==6.10.0
redis==3.2.1
requests-oauthlib==1.2.0 # via django-allauth
requests==2.22.0
s3transfer==0.2.1 # via boto3
redis==3.4.1
requests-oauthlib==1.3.0 # via django-allauth
requests==2.23.0
s3transfer==0.3.3 # via boto3
selenium==3.141.0
six==1.12.0 # via bleach, django-appconf, django-coverage-plugin, django-extensions, env-tools, faker, mock, python-dateutil, tini
sorl-thumbnail==12.5.0
soupsieve==1.9.1 # via beautifulsoup4
sqlparse==0.3.0 # via django, django-debug-toolbar
six==1.14.0 # via bleach, django-coverage-plugin, django-extensions, django-waffle, env-tools, python-dateutil, tini
sorl-thumbnail==12.6.3
soupsieve==2.0 # via beautifulsoup4
sqlparse==0.3.1 # via django, django-debug-toolbar
termcolor==1.1.0
text-unidecode==1.2 # via faker
text-unidecode==1.3 # via faker
tini==3.0.1 # via env-tools
urllib3==1.25.3 # via botocore, requests, selenium
urllib3==1.25.8 # via botocore, requests, selenium
vine==1.3.0 # via amqp, celery
webencodings==0.5.1 # via bleach
whitenoise==4.1.2 # via django-heroku
whitenoise==5.0.1 # via django-heroku
zipp==3.1.0 # via importlib-metadata

# The following packages are considered to be unsafe in a requirements file:
# setuptools
# setuptools==46.1.3 # via gunicorn, markdown

0 comments on commit 9bc79b1

Please sign in to comment.