From 470300b48571b5381035181f8d31bb117447ee4f Mon Sep 17 00:00:00 2001 From: winesoft Date: Wed, 3 Nov 2021 14:11:44 +0900 Subject: [PATCH] 1 1 --- .readthedocs.yaml | 7 +++ requirements/deploy.txt | 25 ++++++++ requirements/docker.txt | 33 +++++++++++ requirements/docs.txt | 4 ++ requirements/lint.txt | 6 ++ requirements/pip.txt | 121 +++++++++++++++++++++++++++++++++++++++ requirements/testing.txt | 23 ++++++++ 7 files changed, 219 insertions(+) create mode 100644 .readthedocs.yaml create mode 100644 requirements/deploy.txt create mode 100644 requirements/docker.txt create mode 100644 requirements/docs.txt create mode 100644 requirements/lint.txt create mode 100644 requirements/pip.txt create mode 100644 requirements/testing.txt diff --git a/.readthedocs.yaml b/.readthedocs.yaml new file mode 100644 index 0000000..42a749d --- /dev/null +++ b/.readthedocs.yaml @@ -0,0 +1,7 @@ +version: 2 +formats: all +sphinx: + configuration: conf.py +python: + install: + - requirements: requirements/docs.txt \ No newline at end of file diff --git a/requirements/deploy.txt b/requirements/deploy.txt new file mode 100644 index 0000000..1481739 --- /dev/null +++ b/requirements/deploy.txt @@ -0,0 +1,25 @@ +# Requirements for our production systems + +-r pip.txt + +# psycopg2 2.9 is not compatible with Django 2.2 +# https://github.com/readthedocs/readthedocs.org/issues/8334 +psycopg2==2.8.6 # pyup: ignore + +gunicorn==20.1.0 + +# Version 3.0.0 drops support for Django < 3.0 +# https://github.com/sebleier/django-redis-cache/#300 +# django-redis-cache==2.1.3 # pyup: ignore +# For some reason 2.1.3 breaks with: +# +# @get_client(write=True) +# def get_or_set(self, client, key, func, timeout=DEFAULT_TIMEOUT): +# if not callable(func): +# raise Exception("Must pass in a callable") +# +# Looks like an older version gets installed somehow +git+https://github.com/sebleier/django-redis-cache.git@2.1.3#egg=django-redis-cache + +#For resizing images +pillow==8.3.2 diff --git a/requirements/docker.txt b/requirements/docker.txt new file mode 100644 index 0000000..3c52f9c --- /dev/null +++ b/requirements/docker.txt @@ -0,0 +1,33 @@ +# Requirements for our local docker development + +-r pip.txt +# https://www.psycopg.org/docs/install.html#psycopg-vs-psycopg-binary +# psycopg2 2.9 is not compatible with Django 2.2 +# https://github.com/readthedocs/readthedocs.org/issues/8334 +psycopg2-binary==2.8.6 # pyup: ignore + +# Version 3.0.0 drops support for Django < 3.0 +# https://github.com/sebleier/django-redis-cache/#300 +django-redis-cache==2.1.3 # pyup: ignore + +# For resizing images +pillow==8.3.2 + +# local debugging tools +watchdog==2.1.6 +datadiff==2.0.0 +ipdb==0.13.9 +pdbpp==0.10.3 + +# jedi 0.18 is incompatible with ipython +# https://github.com/ipython/ipython/issues/12740 +jedi>0.17,<0.18 # pyup: ignore + +# watchdog dependency +argh==0.26.2 + +# run tests +tox==3.24.4 + +# AWS utilities to use against MinIO +awscli==1.20.63 diff --git a/requirements/docs.txt b/requirements/docs.txt new file mode 100644 index 0000000..7e09757 --- /dev/null +++ b/requirements/docs.txt @@ -0,0 +1,4 @@ +# Packages required to build docs, independent of application dependencies + +# Docs +docutils<0.18 diff --git a/requirements/lint.txt b/requirements/lint.txt new file mode 100644 index 0000000..4a71061 --- /dev/null +++ b/requirements/lint.txt @@ -0,0 +1,6 @@ +# Packages required for doing linting + +-r pip.txt + +# prospector 1.5.1 requires some manual updates for its rules +prospector==1.3.1 # pyup: ignore diff --git a/requirements/pip.txt b/requirements/pip.txt new file mode 100644 index 0000000..d08d1aa --- /dev/null +++ b/requirements/pip.txt @@ -0,0 +1,121 @@ +# Base packages + +pip==21.3 +virtualenv==20.8.1 + +django==2.2.24 # pyup: <2.3 +django-extensions==3.1.3 +django_polymorphic==3.0.0 +django-autoslug==1.9.8 +django-simple-history==3.0.0 + +djangorestframework==3.12.4 + +# For intersphinx during builds +Sphinx==4.2.0 + +# Filtering for the REST API +django-filter==21.1 + +drf-flex-fields==0.9.5 +drf-extensions==0.7.1 + +django-vanilla-views==3.0.0 +jsonfield==3.1.0 + +requests==2.26.0 +requests-toolbelt==0.9.1 +slumber==0.7.1 +pyyaml==5.4.1 +Pygments==2.10.0 + +# Basic tools +redis==3.5.3 +kombu==5.1.0 +celery==5.1.2 + +# When upgrading to 0.43.0 we should double check the ``base.html`` change +# described in the changelog. In previous versions, the allauth app included a +# ``base.html`` template. This template could conflict with an equally named +# template at project level. Therefore, ``base.html`` has now been moved to +# ``account/base.html`` -- you will need to check your templates and likely +# override ``account/base.html`` within your project. +django-allauth==0.42.0 # pyup: ignore + +# GitPython >3.1.18 drops support for python 3.6. +GitPython==3.1.18 # pyup: ignore + +# Search +elasticsearch==7.15.1 # pyup: <8.0.0 +elasticsearch-dsl==7.4.0 # pyup: <8.0 +django-elasticsearch-dsl==7.2.0 # pyup: <8.0 +selectolax==0.3.5 + +# embed +pyquery==1.4.3 + +# NOTE: this dep can be removed in python 3.7 in favor of ``date.fromisoformat`` +python-dateutil==2.8.2 + +orjson==3.6.4 + +# Utils +django-gravatar2==1.4.4 +pytz==2021.3 +Unipath==1.1 +django-kombu==0.9.4 +stripe==2.60.0 +regex==2021.10.8 +markdown==3.3.4 + +# unicode-slugify==0.1.5 is not released on PyPI yet +git+https://github.com/mozilla/unicode-slugify@b696c37#egg=unicode-slugify==0.1.5 + +django-formtools==2.3 +django-crispy-forms==1.13.0 + +docker==5.0.3 + +django-textclassifier==1.0 +# django-textclassifier doesn't have pinned versions +# if there is an update they could break our code +nltk==3.6.5 +textblob==0.15.3 + +django-annoying==0.10.6 +django-messages-extends==0.6.2 +djangorestframework-jsonp==1.0.2 +django-taggit==1.5.1 +dj-pagination==2.5.0 + +# Version comparison stuff +packaging==21.0 + +# django-cors-middleware==1.5.0 fails with +# AttributeError: 'dict' object has no attribute 'has_header' +django-cors-middleware==1.4.0 # pyup: ignore + +# User agent parsing - used for analytics purposes +user-agents==2.2.0 + + +# Utilities used to upload build media to cloud storage +# django-storages is pinned to this particular commit because it +# supports generating URLs with other method than GET when using +# private buckets. +# +# Besides, support for the corresponding AWS_BUCKET_ACL and +# AWS_AUTO_CREATE_BUCKET settings have been removed in 1.10. We depend on this +# in our Docker setup. We can upgrade it but we need to add a +# `create_buckets.sh` to be called on `--init` as we used to do for Azurite +# https://github.com/jschneier/django-storages/pull/636 +git+https://github.com/jschneier/django-storages@d0f027c98a877f75615cfc42b4d51c038fa41bf6#egg=django-storages[boto3]==1.9.1 + + +# Required only in development and linting +django-debug-toolbar==3.2.2 + +# For enabling content-security-policy +django-csp==3.7 +# For setting the permissions-policy security header +django-permissions-policy==4.5.0 diff --git a/requirements/testing.txt b/requirements/testing.txt new file mode 100644 index 0000000..03f09b0 --- /dev/null +++ b/requirements/testing.txt @@ -0,0 +1,23 @@ +# Packages required for running tests + +-r pip.txt + +django-dynamic-fixture==3.1.2 +pytest==6.2.5 +pytest-custom-exit-code==0.3.0 +pytest-django==4.4.0 +pytest-xdist==2.4.0 +pytest-cov==3.0.0 +apipkg==2.1.0 +execnet==1.9.0 + +Mercurial==5.9.2 + +yamale==2.2.0 # pyup: <3.0 +pytest-mock==3.6.1 + +# local debugging tools +datadiff==2.0.0 +ipdb==0.13.9 + +requests-mock==1.9.3