gnu: icecat: Update to 78.10.0-guix0-preview1 [security fixes].
[jackhill/guix/guix.git] / gnu / packages / django.scm
index 7f7b96b..dfc3d31 100644 (file)
@@ -1,6 +1,6 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
-;;; Copyright © 2016, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2016, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2017 Nikita <nikita@n0.is>
 ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
@@ -34,6 +34,7 @@
   #:use-module (gnu packages databases)
   #:use-module (gnu packages check)
   #:use-module (gnu packages geo)
+  #:use-module (gnu packages openldap)
   #:use-module (gnu packages python)
   #:use-module (gnu packages python-compression)
   #:use-module (gnu packages python-crypto)
 (define-public python-django
   (package
     (name "python-django")
-    (version "3.1.1")
+    (version "3.1.8")
     (source (origin
               (method url-fetch)
               (uri (pypi-uri "Django" version))
               (sha256
                (base32
-                "0bzwy58hrxbsh7szak1yfh7qvvfnpdpi8ay1x7d3pvbkm1f15j2r"))))
+                "1b0ymqv09b523k3c2jnpb2gjy2fsy6irbfyc2g9x5hjyw41k2fgq"))))
     (build-system python-build-system)
     (arguments
      '(#:phases
@@ -131,13 +132,13 @@ to the @dfn{don't repeat yourself} (DRY) principle.")
 (define-public python-django-2.2
   (package
     (inherit python-django)
-    (version "2.2.16")
+    (version "2.2.20")
     (source (origin
               (method url-fetch)
               (uri (pypi-uri "Django" version))
               (sha256
                (base32
-                "1535g2r322cl4x52fb0dmzlbg23539j2wx6027j54p22xvjlbkv2"))))
+                "0r3a6gbhwngxl172yy6n0sq5knibl2vxc0wbk1g8licfbzfgjs95"))))
     (native-inputs
      `(;; XXX: In 2.2 and 3.0, selenium is required for the test suite.
        ("python-selenium" ,python-selenium)
@@ -165,10 +166,10 @@ to the @dfn{don't repeat yourself} (DRY) principle.")
      `(("python-six" ,python-six)
        ("python-vobject" ,python-vobject)
        ("python-werkzeug" ,python-werkzeug)
-       ("python-dateutil" ,python-dateutil)
-       ("python-django" ,python-django)))
+       ("python-dateutil" ,python-dateutil)))
     (native-inputs
-     `(("python-mock" ,python-mock)
+     `(("python-django" ,python-django)
+       ("python-mock" ,python-mock)
        ("python-factory-boy" ,python-factory-boy)
        ("python-tox" ,python-tox)
        ("python-pytest" ,python-pytest)
@@ -213,10 +214,10 @@ commands, additional database fields and admin extensions.")
                     (lambda _
                       (invoke "python" "runtests.py"))))))
     (native-inputs
-     `(("python-mock" ,python-mock)))
-    (propagated-inputs
      `(("python-django" ,python-django)
-       ("python-six" ,python-six)))
+       ("python-mock" ,python-mock)))
+    (propagated-inputs
+     `(("python-six" ,python-six)))
     (synopsis "Easy-to-use math field/widget captcha for Django forms")
     (description
      "A multi-value-field that presents a human answerable question,
@@ -238,8 +239,6 @@ with arguments to the field constructor.")
     (build-system python-build-system)
     ;; FIXME: How to make the test templates available to Django?
     (arguments '(#:tests? #f))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
     (home-page "https://github.com/divio/django-classy-tags")
     (synopsis "Class based template tags for Django")
     (description
@@ -268,10 +267,10 @@ when coding custom template tags.")
            (lambda _
              (invoke "python3" "-m" "django" "test" "--settings=tests.settings"))))))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-isort" ,python-isort)))
+     `(("python-isort" ,python-isort)))
     (native-inputs
-     `(("python-pytest" ,python-pytest)
+     `(("python-django" ,python-django)
+       ("python-pytest" ,python-pytest)
        ("python-mock" ,python-mock)))
     (home-page
      "https://github.com/jazzband/django-taggit")
@@ -293,9 +292,10 @@ when coding custom template tags.")
         (base32
          "14gzp5cv24z0qhxb7f7k7v9jgzpaj4n8yhjq83ynpx8183fs1rz4"))))
     (build-system python-build-system)
+    (native-inputs
+     `(("python-django" ,python-django)))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-pillow" ,python-pillow)))
+     `(("python-pillow" ,python-pillow)))
     (home-page "https://github.com/SmileyChris/easy-thumbnails")
     (synopsis "Easy thumbnails for Django")
     (description
@@ -346,7 +346,7 @@ size and quality.")
        ;; For tests.
        ("python-pytest-xdist" ,python-pytest-xdist)))
     (propagated-inputs
-     `(("python-pytest" ,python-pytest)))
+     `(("python-pytest" ,python-pytest-6)))
     (home-page "https://pytest-django.readthedocs.org/")
     (synopsis "Django plugin for py.test")
     (description "Pytest-django is a plugin for py.test that provides a set of
@@ -380,11 +380,10 @@ useful tools for testing Django applications and projects.")
                                     "/lib"))
              #t)))
        #:tests? #f)) ; OSError: libgdal.so.27: cannot open shared object file
-    (propagated-inputs
-     `(("python-django" ,python-django)))
     (native-inputs
      `(("gdal" ,gdal)
        ("python-coverage" ,python-coverage)
+       ("python-django" ,python-django)
        ("python-dateutil" ,python-dateutil)
        ("python-geopy" ,python-geopy)
        ("python-mock" ,python-mock)
@@ -457,9 +456,8 @@ them do this.")
        ("python-requests" ,python-requests)
        ("python-requests-oauthlib" ,python-requests-oauthlib)))
     (native-inputs
-     `(("python-mock" ,python-mock)))
-    (inputs
-     `(("python-django" ,python-django)))
+     `(("python-django" ,python-django)
+       ("python-mock" ,python-mock)))
     (home-page "https://github.com/pennersr/django-allauth")
     (synopsis "Set of Django applications addressing authentication")
     (description
@@ -484,10 +482,10 @@ account authentication.")
          "14069rlgjd5g724iaglai0nc636g9km4ba56r4j3k84chibqzn03"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-sqlparse" ,python-sqlparse)
-       ("python-django" ,python-django)))
+     `(("python-sqlparse" ,python-sqlparse)))
     (native-inputs
-     `(("python-django-jinja" ,python-django-jinja)
+     `(("python-django" ,python-django)
+       ("python-django-jinja" ,python-django-jinja)
        ("python-html5lib" ,python-html5lib)))
     (arguments
      '(#:phases
@@ -503,6 +501,31 @@ account authentication.")
 request and response as a toolbar on the rendered page.")
     (license license:bsd-3)))
 
+(define-public python-django-debug-toolbar-alchemy
+  (package
+    (name "python-django-debug-toolbar-alchemy")
+    (version "0.1.5")
+    (home-page "https://github.com/miki725/django-debug-toolbar-alchemy")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "django-debug-toolbar-alchemy" version))
+              (sha256
+               (base32
+                "1kmpzghnsc247bc1dl22s4y62k9ijgy1pjms227018h5a4frsa5b"))))
+    (build-system python-build-system)
+    (arguments '(#:tests? #f))          ;XXX: 'make check' does "echo TODO"
+    (propagated-inputs
+     `(("python-django-debug-toolbar" ,python-django-debug-toolbar)
+       ("python-jsonplus" ,python-jsonplus)
+       ("python-six" ,python-six)
+       ("python-sqlalchemy" ,python-sqlalchemy)))
+    (synopsis "Django Debug Toolbar panel for SQLAlchemy")
+    (description
+     "This package completely mimics the default Django Debug Toolbar SQL
+panel (internally it is actually subclassed), but instead of displaying
+queries done via the Django ORM, SQLAlchemy generated queries are displayed.")
+    (license license:expat)))
+
 (define-public python-django-gravatar2
   (package
     (name "python-django-gravatar2")
@@ -539,10 +562,10 @@ templatetags and a full test suite.")
                 "0fc6i77faxxv1gjlp06lv3kw64b5bhdiypaygfxh5djddgk83fwa"))))
     (build-system python-build-system)
     (native-inputs
-     `(("python-nose" ,python-nose)))
-    (propagated-inputs
      `(("python-django" ,python-django)
-       ("python-webassets" ,python-webassets)))
+       ("python-nose" ,python-nose)))
+    (propagated-inputs
+     `(("python-webassets" ,python-webassets)))
     (home-page "https://github.com/miracle2k/django-assets")
     (synopsis "Asset management for Django")
     (description
@@ -567,8 +590,7 @@ merging, minifying and compiling CSS and Javascript files.")
          "06ldbkfkm6sc0p9sqpjph06gxrqpj78ih3dc2yik2fcba2y5mak1"))))
     (build-system python-build-system)
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-jinja2" ,python-jinja2)
+     `(("python-jinja2" ,python-jinja2)
        ("python-pytz" ,python-pytz)
        ("python-django-pipeline" ,python-django-pipeline)))
     (arguments
@@ -592,33 +614,9 @@ provides certain advantages over the builtin Jinja2 backend in Django, for
 example, explicit calls to callables from templates and better performance.")
     (license license:bsd-3)))
 
+;; JSONField is now built-in to Django, obsoleting this package.
 (define-public python-django-jsonfield
-  (package
-    (name "python-django-jsonfield")
-    (version "1.0.3")
-    (source (origin
-              (method url-fetch)
-              (uri (pypi-uri "jsonfield" version))
-              (sha256
-               (base32
-                "19x4lak0hg9c20r7mvf27w7i8r6i4sg2g0ypmlmp2665fnk76zvy"))))
-    (build-system python-build-system)
-    (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (add-before 'check 'fix-tests
-           (lambda _
-             (substitute* "jsonfield/tests.py"
-               (("django.forms.util") "django.forms.utils")))))))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
-    (home-page "https://github.com/bradjasper/django-jsonfield")
-    (synopsis "Store validated JSON in your model")
-    (description
-      "Django-jsonfield is a reusable Django field that allows you to store
-validated JSON in your model.  It silently takes care of serialization.  To
-use, simply add the field to one of your models.")
-    (license license:expat)))
+  (deprecated-package "python-django-jsonfield" python-django))
 
 (define-public python-dj-database-url
   (package
@@ -665,7 +663,7 @@ conn_max_age argument to easily enable Django’s connection pool.")
                     (lambda _
                       (invoke "python" "-m" "django" "test" "-v2"
                               "--settings=tests.settings"))))))
-    (propagated-inputs `(("python-django" ,python-django)))
+    (native-inputs `(("python-django" ,python-django)))
     (synopsis "Pickled object field for Django")
     (description "Pickled object field for Django")
     (license license:expat)))
@@ -684,8 +682,6 @@ conn_max_age argument to easily enable Django’s connection pool.")
     (arguments
      ;; XXX: Tests require a Postgres database.
      `(#:tests? #f))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
     (home-page "https://github.com/aykut/django-bulk-update")
     (synopsis "Simple bulk update over Django ORM or with helper function")
     (description
@@ -715,9 +711,8 @@ project aims to bulk update given objects using one query over Django ORM.")
              (invoke "coverage" "run" "--source" "contact_form"
                      "runtests.py"))))))
     (native-inputs
-     `(("python-coverage" ,python-coverage)))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
+     `(("python-coverage" ,python-coverage)
+       ("python-django" ,python-django)))
     (home-page "https://github.com/ubernostrum/django-contact-form")
     (synopsis "Contact form for Django")
     (description
@@ -736,8 +731,10 @@ for Django sites.")
                (base32
                 "0ccdiv784a5vnpfal36km4dyg12340rwhpr0riyy0k89wfnjn8yi"))))
     (build-system python-build-system)
-    (propagated-inputs
+    (native-inputs
      `(("python-django" ,python-django)))
+    (propagated-inputs
+     `(("python-six" ,python-six)))
     (home-page "https://github.com/django/django-contrib-comments")
     (synopsis "Comments framework")
     (description
@@ -747,36 +744,6 @@ used to attach comments to any model, so you can use it for comments on blog
 entries, photos, book chapters, or anything else.")
     (license license:bsd-3)))
 
-(define-public python-django-overextends
-  (package
-    (name "python-django-overextends")
-    (version "0.4.3")
-    (source (origin
-              (method url-fetch)
-              (uri (pypi-uri "django-overextends" version))
-              (sha256
-               (base32
-                "0qc2pcf3i56pmfxh2jw7k3pgljd8xzficmkl2541n7bkcbngqfzm"))))
-    (build-system python-build-system)
-    (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (replace 'check
-           (lambda _ (invoke "./test_project/manage.py" "test"))))))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
-    (native-inputs
-     `(("sphinx-me" ,python-sphinx-me)))
-    (home-page "https://github.com/stephenmcd/django-overextends")
-    (synopsis "Circular template inheritance")
-    (description
-      "A Django reusable app providing the overextends template tag, a drop-in
-replacement for Django's extends tag, which allows you to use circular template
-inheritance.  The primary use-case for overextends is to simultaneously
-override and extend templates from other reusable apps, in your own Django
-project.")
-    (license license:bsd-2)))
-
 (define-public python-django-pipeline
   (package
     (name "python-django-pipeline")
@@ -807,9 +774,10 @@ project.")
                                        (getenv "PYTHONPATH")))
                 (setenv "DJANGO_SETTINGS_MODULE" "tests.settings")
                 (invoke "django-admin" "test" "tests"))))))))
+    (native-inputs
+     `(("python-django" ,python-django)))
     (propagated-inputs
      `(("python-css-html-js-minify" ,python-css-html-js-minify)
-       ("python-django" ,python-django)
        ("python-slimit" ,python-slimit)
        ("python-jsmin" ,python-jsmin)))
     (home-page
@@ -841,14 +809,14 @@ support, and optional data-URI image and font embedding.")
              (with-directory-excursion "tests"
                (invoke "python" "runtests.py")))))))
     (native-inputs
-     `(("python-fakeredis" ,python-fakeredis)
+     `(("python-django" ,python-django)
+       ("python-fakeredis" ,python-fakeredis)
        ("python-hiredis" ,python-hiredis)
        ("python-mock" ,python-mock)
        ("python-msgpack" ,python-msgpack)
        ("redis" ,redis)))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-redis" ,python-redis)))
+     `(("python-redis" ,python-redis)))
     (home-page "https://github.com/niwibe/django-redis")
     (synopsis "Full featured redis cache backend for Django")
     (description
@@ -876,13 +844,13 @@ support, and optional data-URI image and font embedding.")
                      "--settings=django_rq.tests.settings"
                      "--pythonpath=."))))))
     (native-inputs
-     `(("python-django-redis" ,python-django-redis)
+     `(("python-django" ,python-django)
+       ("python-django-redis" ,python-django-redis)
        ("python-mock" ,python-mock)
        ("python-rq-scheduler" ,python-rq-scheduler)
        ("redis" ,redis)))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-rq" ,python-rq)))
+     `(("python-rq" ,python-rq)))
     (home-page "https://github.com/ui/django-rq")
     (synopsis "Django integration with RQ")
     (description
@@ -894,21 +862,21 @@ settings.py and easily use them in your project.")
 (define-public python-django-q
   (package
     (name "python-django-q")
-    (version "1.3.3")
+    (version "1.3.4")
     (source
       (origin
         (method url-fetch)
         (uri (pypi-uri "django-q" version))
         (sha256
-         (base32
-          "1fs29767940akbsn3vdzw2rqnn9v77b0b55bi7fvydny1rk7fw6y"))))
+         (base32 "03z1pf6wlf47i7afr79a8fiiidfk1vq19yaqnv0m4qdny7f58gaj"))))
     (build-system python-build-system)
     ;; FIXME: Tests require disque, Redis, MongoDB, Docker.
     (arguments '(#:tests? #f))
+    (native-inputs
+     `(("python-django" ,python-django)))
     (propagated-inputs
      `(("python-arrow" ,python-arrow)
        ("python-blessed" ,python-blessed)
-       ("python-django" ,python-django)
        ("python-django-picklefield" ,python-django-picklefield)))
     (home-page "https://django-q.readthedocs.io/")
     (synopsis "Multiprocessing distributed task queue for Django")
@@ -936,7 +904,7 @@ using Python multiprocessing.")
                                                           "./build/lib:.:"
                                                           (getenv "PYTHONPATH")))
                       (invoke "django-admin.py" "test" "--settings=settings"))))))
-    (propagated-inputs
+    (native-inputs
      `(("python-django" ,python-django)))
     (home-page "https://github.com/jazzband/django-sortedm2m")
     (synopsis "Drop-in replacement for django's own ManyToManyField")
@@ -965,7 +933,7 @@ the order of added relations.")
                                                           (getenv "PYTHONPATH")))
                       (setenv "DJANGO_SETTINGS_MODULE" "tests.test_settings")
                       (invoke "django-admin.py" "test" "-v2"))))))
-    (propagated-inputs
+    (native-inputs
      `(("python-django" ,python-django)))
     (home-page "https://github.com/django-compressor/django-appconf")
     (synopsis "Handle configuration defaults of packaged Django apps")
@@ -1002,11 +970,11 @@ name is purely coincidental.")
                       (setenv "DJANGO_SETTINGS_MODULE" "project.settings")
                       (invoke "pytest" "-vv"))))))
     (native-inputs
-     `(("python-pytest" ,python-pytest)
+     `(("python-django" ,python-django)
+       ("python-pytest" ,python-pytest)
        ("python-pytest-django" ,python-pytest-django)))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("django-appconf" ,python-django-appconf)))
+     `(("django-appconf" ,python-django-appconf)))
     (synopsis "Generate JavaScript catalog to static files")
     (description
       "A Django app that provides helper for generating JavaScript catalog to
@@ -1044,25 +1012,23 @@ Django projects, which allows association of a number of tags with any
 (define-public python-djangorestframework
   (package
     (name "python-djangorestframework")
-    (version "3.11.1")
+    (version "3.12.1")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "djangorestframework" version))
        (sha256
         (base32
-         "0chbl1d0m1x23mmpdj7y85k3n32lpxrhcdl07ywnylfj9dd2vl3d"))))
+         "0jb22psb823vh5fj9az63p5lgyax9ygjy2faah16ajxvvsp54i6m"))))
     (build-system python-build-system)
     (arguments
      '(;; No included tests
        #:tests? #f))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
     (home-page "https://www.django-rest-framework.org")
     (synopsis "Toolkit for building Web APIs with Django")
     (description
      "The Django REST framework is for building Web APIs with Django.  It
-provides features like a web browseable API and authentication policies.")
+provides features like a Web-browsable API and authentication policies.")
     (license license:bsd-2)))
 
 (define-public python-django-sekizai
@@ -1078,13 +1044,14 @@ provides features like a web browseable API and authentication policies.")
           "0vrkli625b5s1wldri3dyrfvqbxg7zxy2pg0rpjixw3b1ndz0ag8"))))
     (build-system python-build-system)
     (arguments '(#:tests? #f)) ; Tests not included with release.
+    (native-inputs
+     `(("python-django" ,python-django)))
     (propagated-inputs
-     `(("python-django" ,python-django)
-       ("python-django-classy-tags" ,python-django-classy-tags)
+     `(("python-django-classy-tags" ,python-django-classy-tags)
        ("python-six" ,python-six)))
     (home-page "https://github.com/divio/django-sekizai")
     (synopsis "Template blocks for Django projects")
-    (description "Sekizai means blocks in Japanese, and thats what this app
+    (description "Sekizai means blocks in Japanese, and that is what this app
 provides.  A fresh look at blocks.  With @code{django-sekizai} you can define
 placeholders where your blocks get rendered and at different places in your
 templates append to those blocks.  This is especially useful for css and
@@ -1109,7 +1076,7 @@ a single block.")
     (arguments
      '(;; No included tests
        #:tests? #f))
-    (propagated-inputs
+    (native-inputs
      `(("python-django" ,python-django)))
     (home-page
      "http://github.com/maraujop/django-crispy-forms")
@@ -1185,11 +1152,144 @@ template tag.")
                     (lambda _
                       (invoke "python" "runtests.py"))))))
     (native-inputs
-     `(("python-mock" ,python-mock)))
-    (propagated-inputs
-     `(("python-django" ,python-django)))
+     `(("python-django" ,python-django)
+       ("python-mock" ,python-mock)))
     (synopsis "Django test helpers to manage file storage side effects")
     (description
      "This project provides tools to help reduce the side effects of using
 FileFields during tests.")
     (license license:expat)))
+
+(define-public python-django-auth-ldap
+  (package
+    (name "python-django-auth-ldap")
+    (version "2.2.0")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "django-auth-ldap" version))
+              (sha256
+               (base32
+                "1gq49l5lv6ar6yf73c8pix8n7md4109yq31s5jfk64w6n1rigbqi"))))
+    (build-system python-build-system)
+    (arguments
+     '(#:phases (modify-phases %standard-phases
+                  (replace 'check
+                    (lambda* (#:key inputs #:allow-other-keys)
+                      (let ((openldap (assoc-ref inputs "openldap")))
+                        ;; The tests need 'slapd' which is installed to the
+                        ;; libexec directory of OpenLDAP.
+                        (setenv "SLAPD" (string-append openldap "/libexec/slapd"))
+                        (setenv "SCHEMA"
+                                (string-append openldap "/etc/openldap/schema"))
+                        (invoke "python" "-m" "django" "test"
+                                "--settings" "tests.settings")))))))
+    (native-inputs
+     `(("openldap" ,openldap)
+       ("python-django" ,python-django)
+       ("python-mock" ,python-mock)))
+    (propagated-inputs
+     `(("python-ldap" ,python-ldap)))
+    (home-page "https://github.com/django-auth-ldap/django-auth-ldap")
+    (synopsis "Django LDAP authentication backend")
+    (description
+     "This package provides an LDAP authentication backend for Django.")
+    (license license:bsd-2)))
+
+(define-public python-django-logging-json
+  (package
+    (name "python-django-logging-json")
+    (version "1.15")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "django-logging-json" version))
+              (sha256
+               (base32
+                "06041a8icazzp73kg93c7k1ska12wvkq7fpcad0l0sm1qnxx5yx7"))))
+    (build-system python-build-system)
+    (arguments '(#:tests? #f))          ;no tests
+    (native-inputs
+     `(("python-django" ,python-django)))
+    (propagated-inputs
+     `(("python-certifi" ,python-certifi)
+       ("python-elasticsearch" ,python-elasticsearch)
+       ("python-six" ,python-six)))
+    (home-page "https://github.com/cipriantarta/django-logging")
+    (synopsis "Log requests/responses in various formats")
+    (description
+     "This package provides a Django library that logs request, response,
+and exception details in a JSON document.  It can also send logs directly
+to ElasticSearch.")
+    (license license:bsd-2)))
+
+(define-public python-django-netfields
+  (package
+    (name "python-django-netfields")
+    (version "1.2.2")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "django-netfields" version))
+              (sha256
+               (base32
+                "1c47azr5am0q8g45x0fbn0cay7vyrack6n7k6siliw1j2p0gzi7s"))))
+    (build-system python-build-system)
+    (arguments '(#:tests? #f))      ;XXX: Requires a running PostgreSQL server
+    (native-inputs
+     `(("python-django" ,python-django)))
+    (propagated-inputs
+     `(("python-ipaddress" ,python-ipaddress)
+       ("python-netaddr" ,python-netaddr)
+       ("python-six" ,python-six)))
+    (home-page "https://github.com/jimfunk/django-postgresql-netfields")
+    (synopsis "PostgreSQL netfields implementation for Django")
+    (description
+     "This package provides mappings for the PostgreSQL @code{INET} and
+@code{CIDR} fields for use in Django projects.")
+    (license license:bsd-3)))
+
+(define-public python-django-url-filter
+  (package
+    (name "python-django-url-filter")
+    (version "0.3.15")
+    (home-page "https://github.com/miki725/django-url-filter")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference (url home-page) (commit version)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0r4zhqhs8y6cnplwyvcb0zpijizw1ifnszs38n4w8138657f9026"))))
+    (build-system python-build-system)
+    (arguments
+     '(#:tests? #f            ;FIXME: Django raises "Apps aren't loaded yet"!?
+       #:phases (modify-phases %standard-phases
+                  (add-before 'check 'loosen-requirements
+                    (lambda _
+                      ;; Do not depend on compatibility package for old
+                      ;; Python versions.
+                      (substitute* "requirements.txt"
+                        (("enum-compat") ""))
+                      #t))
+                  (replace 'check
+                    (lambda* (#:key tests? #:allow-other-keys)
+                      (if tests?
+                          (begin
+                            (setenv "PYTHONPATH"
+                                    (string-append "./build/lib:.:"
+                                                   (getenv "PYTHONPATH")))
+                            (setenv "DJANGO_SETTINGS_MODULE"
+                                    "test_project.settings")
+                            (invoke "pytest" "-vv" "--doctest-modules"
+                                    "tests/" "url_filter/"))
+                          (format #t "test suite not run~%")))))))
+    (native-inputs
+     `(("python-django" ,python-django)))
+    (propagated-inputs
+     `(("python-cached-property" ,python-cached-property)
+       ("python-six" ,python-six)))
+    (synopsis "Filter data via human-friendly URLs")
+    (description
+     "The main goal of Django URL Filter is to provide an easy URL interface
+for filtering data.  It allows the user to safely filter by model attributes
+and also specify the lookup type for each filter (very much like
+Django's filtering system in ORM).")
+    (license license:expat)))