diff -Nru djangorestframework-gis-0.10.1/AUTHORS djangorestframework-gis-0.11/AUTHORS --- djangorestframework-gis-0.10.1/AUTHORS 2015-06-28 18:09:38.000000000 +0000 +++ djangorestframework-gis-0.11/AUTHORS 2016-04-01 16:41:00.000000000 +0000 @@ -9,3 +9,4 @@ Federico Capoano https://github.com/nemesisdesign/ Shanto https://github.com/Shanto Eric Theise https://github.com/erictheise +Asif Saifuddin https://github.com/auvipy diff -Nru djangorestframework-gis-0.10.1/CHANGES.rst djangorestframework-gis-0.11/CHANGES.rst --- djangorestframework-gis-0.10.1/CHANGES.rst 2016-01-06 12:10:38.000000000 +0000 +++ djangorestframework-gis-0.11/CHANGES.rst 2016-11-22 12:27:40.000000000 +0000 @@ -1,6 +1,14 @@ Changelog ========= +Version 0.11.0 [2016-11-22] +--------------------------- + +- `#106 `_: dropped support for django 1.7 +- `#117 `_: added support for django-filter 0.15 +- `6479949 `_: fixed tests for latest DRF 3.5 version +- `35e3b87 `_: added official support to django 1.10 + Version 0.10.1 [2016-01-06] --------------------------- diff -Nru djangorestframework-gis-0.10.1/debian/changelog djangorestframework-gis-0.11/debian/changelog --- djangorestframework-gis-0.10.1/debian/changelog 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/changelog 2016-11-23 20:09:11.000000000 +0000 @@ -1,3 +1,9 @@ +djangorestframework-gis (0.11-1) unstable; urgency=low + + * New upstream release. + + -- Michael Fladischer Wed, 23 Nov 2016 21:09:11 +0100 + djangorestframework-gis (0.10.1-2) unstable; urgency=medium * Add patches to fix tests with Django 1.8+ (Closes: #834669). diff -Nru djangorestframework-gis-0.10.1/debian/.git-dpm djangorestframework-gis-0.11/debian/.git-dpm --- djangorestframework-gis-0.10.1/debian/.git-dpm 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/.git-dpm 2016-11-23 20:09:11.000000000 +0000 @@ -1,11 +1,11 @@ # see git-dpm(1) from git-dpm package -d583df97edba5e5286bfd17f5b712818cd4c0bac -d583df97edba5e5286bfd17f5b712818cd4c0bac -8623397eb64f78e06c01bde72ff6eb77185328e2 -8623397eb64f78e06c01bde72ff6eb77185328e2 -djangorestframework-gis_0.10.1.orig.tar.gz -f048cdeab8372d5c2f4db10d555a7d09b77315df -26301 +a00e23a9013ec37e22dbf739909d31c94b52711e +a00e23a9013ec37e22dbf739909d31c94b52711e +5fd992e9c7cd507886df9266d61631d81cbfc90e +5fd992e9c7cd507886df9266d61631d81cbfc90e +djangorestframework-gis_0.11.orig.tar.gz +5f83223fd778587e3206d61203bf5b8e9a008e35 +27285 debianTag="debian/%e%v" patchedTag="patched/%e%v" upstreamTag="upstream/%e%u" diff -Nru djangorestframework-gis-0.10.1/debian/patches/0002-Do-not-import-local-settings-for-tests.patch djangorestframework-gis-0.11/debian/patches/0002-Do-not-import-local-settings-for-tests.patch --- djangorestframework-gis-0.10.1/debian/patches/0002-Do-not-import-local-settings-for-tests.patch 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/0002-Do-not-import-local-settings-for-tests.patch 2016-11-23 20:09:11.000000000 +0000 @@ -1,4 +1,4 @@ -From f87e07883c1e34ec00586079ac524c922de288df Mon Sep 17 00:00:00 2001 +From a54af50f2774f3ca35fa4326c0bcf84dd3325d44 Mon Sep 17 00:00:00 2001 From: Michael Fladischer Date: Thu, 7 Jan 2016 12:23:10 +0100 Subject: Do not import local settings for tests. @@ -8,10 +8,10 @@ 1 file changed, 6 deletions(-) diff --git a/tests/settings.py b/tests/settings.py -index d9edb92..0299ffc 100644 +index c628f97..0fb4e30 100644 --- a/tests/settings.py +++ b/tests/settings.py -@@ -55,9 +55,3 @@ STATIC_URL = '/static/' +@@ -75,9 +75,3 @@ STATIC_URL = '/static/' ANONYMOUS_USER_ID=-1 TEMPLATE_STRING_IF_INVALID = 'INVALID_TEMPLATE: %s END_INVALID_TEMPLATE' diff -Nru djangorestframework-gis-0.10.1/debian/patches/0003-Add-TEMPLATES-setting-for-Django-1.8.patch djangorestframework-gis-0.11/debian/patches/0003-Add-TEMPLATES-setting-for-Django-1.8.patch --- djangorestframework-gis-0.10.1/debian/patches/0003-Add-TEMPLATES-setting-for-Django-1.8.patch 1970-01-01 00:00:00.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/0003-Add-TEMPLATES-setting-for-Django-1.8.patch 2016-11-23 20:09:11.000000000 +0000 @@ -0,0 +1,36 @@ +From a00e23a9013ec37e22dbf739909d31c94b52711e Mon Sep 17 00:00:00 2001 +From: Michael Fladischer +Date: Mon, 17 Oct 2016 13:44:45 +0200 +Subject: Add TEMPLATES setting for Django 1.8+. + +--- + tests/settings.py | 19 +++++++++++++++++++ + 1 file changed, 19 insertions(+) + +diff --git a/tests/settings.py b/tests/settings.py +index 0fb4e30..a419f71 100644 +--- a/tests/settings.py ++++ b/tests/settings.py +@@ -75,3 +75,22 @@ STATIC_URL = '/static/' + ANONYMOUS_USER_ID=-1 + + TEMPLATE_STRING_IF_INVALID = 'INVALID_TEMPLATE: %s END_INVALID_TEMPLATE' ++ ++TEMPLATES = [ ++ { ++ 'BACKEND': 'django.template.backends.django.DjangoTemplates', ++ 'DIRS': [], ++ 'APP_DIRS': True, ++ 'OPTIONS': { ++ 'context_processors': [ ++ 'django.contrib.auth.context_processors.auth', ++ 'django.template.context_processors.debug', ++ 'django.template.context_processors.i18n', ++ 'django.template.context_processors.media', ++ 'django.template.context_processors.static', ++ 'django.template.context_processors.tz', ++ 'django.contrib.messages.context_processors.messages', ++ ], ++ }, ++ }, ++] diff -Nru djangorestframework-gis-0.10.1/debian/patches/0003-Fix-URL-config-for-Django-1.8.patch djangorestframework-gis-0.11/debian/patches/0003-Fix-URL-config-for-Django-1.8.patch --- djangorestframework-gis-0.10.1/debian/patches/0003-Fix-URL-config-for-Django-1.8.patch 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/0003-Fix-URL-config-for-Django-1.8.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,94 +0,0 @@ -From b1f918e9e832b2275887bdad2d4f46dc8a8e7926 Mon Sep 17 00:00:00 2001 -From: Michael Fladischer -Date: Mon, 17 Oct 2016 13:43:32 +0200 -Subject: Fix URL config for Django 1.8+. - ---- - tests/django_restframework_gis_tests/urls.py | 48 +++++++++++++++------------- - tests/urls.py | 3 +- - 2 files changed, 27 insertions(+), 24 deletions(-) - -diff --git a/tests/django_restframework_gis_tests/urls.py b/tests/django_restframework_gis_tests/urls.py -index 8df2837..2c97fd3 100644 ---- a/tests/django_restframework_gis_tests/urls.py -+++ b/tests/django_restframework_gis_tests/urls.py -@@ -1,35 +1,37 @@ --from django.conf.urls import patterns, url -+from django.conf.urls import url - -+from django_restframework_gis_tests import views - --urlpatterns = patterns('django_restframework_gis_tests.views', -- url(r'^$', 'location_list', name='api_location_list'), -- url(r'^(?P[0-9]+)/$', 'location_details', name='api_location_details'), -+ -+urlpatterns = [ -+ url(r'^$', views.location_list, name='api_location_list'), -+ url(r'^(?P[0-9]+)/$', views.location_details, name='api_location_details'), - - # geojson -- url(r'^geojson/$', 'geojson_location_list', name='api_geojson_location_list'), -- url(r'^geojson/(?P[0-9]+)/$', 'geojson_location_details', name='api_geojson_location_details'), -- url(r'^geojson_hidden/(?P[0-9]+)/$', 'geojson_location_details_hidden', name='api_geojson_location_details_hidden'), -- url(r'^geojson_none/(?P[0-9]+)/$', 'geojson_location_details_none', name='api_geojson_location_details_none'), -- url(r'^geojson/(?P[-\w]+)/$', 'geojson_location_slug_details', name='api_geojson_location_slug_details'), -- url(r'^geojson-falseid/(?P[0-9]+)/$', 'geojson_location_falseid_details', name='api_geojson_location_falseid_details'), -- url(r'^geojson-noid/(?P[0-9]+)/$', 'geojson_location_noid_details', name='api_geojson_location_noid_details'), -+ url(r'^geojson/$', views.geojson_location_list, name='api_geojson_location_list'), -+ url(r'^geojson/(?P[0-9]+)/$', views.geojson_location_details, name='api_geojson_location_details'), -+ url(r'^geojson_hidden/(?P[0-9]+)/$', views.geojson_location_details_hidden, name='api_geojson_location_details_hidden'), -+ url(r'^geojson_none/(?P[0-9]+)/$', views.geojson_location_details_none, name='api_geojson_location_details_none'), -+ url(r'^geojson/(?P[-\w]+)/$', views.geojson_location_slug_details, name='api_geojson_location_slug_details'), -+ url(r'^geojson-falseid/(?P[0-9]+)/$', views.geojson_location_falseid_details, name='api_geojson_location_falseid_details'), -+ url(r'^geojson-noid/(?P[0-9]+)/$', views.geojson_location_noid_details, name='api_geojson_location_noid_details'), - - # file -- url(r'^geojson-file/(?P[0-9]+)/$', 'geojson_located_file_details', name='api_geojson_located_file_details'), -+ url(r'^geojson-file/(?P[0-9]+)/$', views.geojson_located_file_details, name='api_geojson_located_file_details'), - - # geojson with bbox with its own geometry field -- url(r'^geojson-with-bbox/$', 'geojson_boxedlocation_list', name='api_geojson_boxedlocation_list'), -- url(r'^geojson-with-bbox/(?P[0-9]+)/$', 'geojson_boxedlocation_details', name='api_geojson_boxedlocation_details'), -+ url(r'^geojson-with-bbox/$', views.geojson_boxedlocation_list, name='api_geojson_boxedlocation_list'), -+ url(r'^geojson-with-bbox/(?P[0-9]+)/$', views.geojson_boxedlocation_details, name='api_geojson_boxedlocation_details'), - - # geojson with bbox with autogenerated bbox -- url(r'^geojson-with-auto-bbox/$', 'geojson_location_bbox_list', name='api_geojson_location_bbox_list'), -+ url(r'^geojson-with-auto-bbox/$', views.geojson_location_bbox_list, name='api_geojson_location_bbox_list'), - - # Filters -- url(r'^filters/contained_in_bbox$', 'geojson_location_contained_in_bbox_list', name='api_geojson_location_list_contained_in_bbox_filter'), -- url(r'^filters/overlaps_bbox$', 'geojson_location_overlaps_bbox_list', name='api_geojson_location_list_overlaps_bbox_filter'), -- url(r'^filters/contained_in_geometry$', 'geojson_contained_in_geometry', name='api_geojson_contained_in_geometry'), -- url(r'^filters/contained_in_tile$', 'geojson_location_contained_in_tile_list', name='api_geojson_location_list_contained_in_tile_filter'), -- url(r'^filters/overlaps_tile$', 'geojson_location_overlaps_tile_list', name='api_geojson_location_list_overlaps_tile_filter'), -- url(r'^filters/within_distance_of_point$', 'geojson_location_within_distance_of_point_list', name='api_geojson_location_list_within_distance_of_point_filter'), -- url(r'^filters/within_degrees_of_point$', 'geojson_location_within_degrees_of_point_list', name='api_geojson_location_list_within_degrees_of_point_filter'), --) -+ url(r'^filters/contained_in_bbox$', views.geojson_location_contained_in_bbox_list, name='api_geojson_location_list_contained_in_bbox_filter'), -+ url(r'^filters/overlaps_bbox$', views.geojson_location_overlaps_bbox_list, name='api_geojson_location_list_overlaps_bbox_filter'), -+ url(r'^filters/contained_in_geometry$', views.geojson_contained_in_geometry, name='api_geojson_contained_in_geometry'), -+ url(r'^filters/contained_in_tile$', views.geojson_location_contained_in_tile_list, name='api_geojson_location_list_contained_in_tile_filter'), -+ url(r'^filters/overlaps_tile$', views.geojson_location_overlaps_tile_list, name='api_geojson_location_list_overlaps_tile_filter'), -+ url(r'^filters/within_distance_of_point$', views.geojson_location_within_distance_of_point_list, name='api_geojson_location_list_within_distance_of_point_filter'), -+ url(r'^filters/within_degrees_of_point$', views.geojson_location_within_degrees_of_point_list, name='api_geojson_location_list_within_degrees_of_point_filter'), -+] -diff --git a/tests/urls.py b/tests/urls.py -index 3f14318..8db5e95 100644 ---- a/tests/urls.py -+++ b/tests/urls.py -@@ -1,5 +1,6 @@ - from django.conf.urls import include, url - from django.contrib import admin -+from django.contrib.staticfiles.views import serve - - admin.autodiscover() - -@@ -12,6 +13,6 @@ urlpatterns = [ - - url(r'', include('django_restframework_gis_tests.urls')), - -- url(r'^static/(?P.*)$', 'django.contrib.staticfiles.views.serve'), -+ url(r'^static/(?P.*)$', serve), - - ] diff -Nru djangorestframework-gis-0.10.1/debian/patches/0004-Add-TEMPLATES-setting-for-Django-1.8.patch djangorestframework-gis-0.11/debian/patches/0004-Add-TEMPLATES-setting-for-Django-1.8.patch --- djangorestframework-gis-0.10.1/debian/patches/0004-Add-TEMPLATES-setting-for-Django-1.8.patch 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/0004-Add-TEMPLATES-setting-for-Django-1.8.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,36 +0,0 @@ -From d583df97edba5e5286bfd17f5b712818cd4c0bac Mon Sep 17 00:00:00 2001 -From: Michael Fladischer -Date: Mon, 17 Oct 2016 13:44:45 +0200 -Subject: Add TEMPLATES setting for Django 1.8+. - ---- - tests/settings.py | 19 +++++++++++++++++++ - 1 file changed, 19 insertions(+) - -diff --git a/tests/settings.py b/tests/settings.py -index 0299ffc..ed1ee17 100644 ---- a/tests/settings.py -+++ b/tests/settings.py -@@ -55,3 +55,22 @@ STATIC_URL = '/static/' - ANONYMOUS_USER_ID=-1 - - TEMPLATE_STRING_IF_INVALID = 'INVALID_TEMPLATE: %s END_INVALID_TEMPLATE' -+ -+TEMPLATES = [ -+ { -+ 'BACKEND': 'django.template.backends.django.DjangoTemplates', -+ 'DIRS': [], -+ 'APP_DIRS': True, -+ 'OPTIONS': { -+ 'context_processors': [ -+ 'django.contrib.auth.context_processors.auth', -+ 'django.template.context_processors.debug', -+ 'django.template.context_processors.i18n', -+ 'django.template.context_processors.media', -+ 'django.template.context_processors.static', -+ 'django.template.context_processors.tz', -+ 'django.contrib.messages.context_processors.messages', -+ ], -+ }, -+ }, -+] diff -Nru djangorestframework-gis-0.10.1/debian/patches/series djangorestframework-gis-0.11/debian/patches/series --- djangorestframework-gis-0.10.1/debian/patches/series 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/series 2016-11-23 20:09:11.000000000 +0000 @@ -1,4 +1,3 @@ spatialite.patch 0002-Do-not-import-local-settings-for-tests.patch -0003-Fix-URL-config-for-Django-1.8.patch -0004-Add-TEMPLATES-setting-for-Django-1.8.patch +0003-Add-TEMPLATES-setting-for-Django-1.8.patch diff -Nru djangorestframework-gis-0.10.1/debian/patches/spatialite.patch djangorestframework-gis-0.11/debian/patches/spatialite.patch --- djangorestframework-gis-0.10.1/debian/patches/spatialite.patch 2016-10-17 12:02:17.000000000 +0000 +++ djangorestframework-gis-0.11/debian/patches/spatialite.patch 2016-11-23 20:09:11.000000000 +0000 @@ -1,4 +1,4 @@ -From bac492a7f71395bf70133163a7dbbc765ac0dd23 Mon Sep 17 00:00:00 2001 +From 7695f49eb8ecce08ba1c036f94416114710fd7b6 Mon Sep 17 00:00:00 2001 From: Michael Fladischer Date: Thu, 8 Oct 2015 08:58:54 -0700 Subject: Use spatialite backend for tests. @@ -17,7 +17,7 @@ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tests/settings.py b/tests/settings.py -index 150eb82..d9edb92 100644 +index 39b5df0..c628f97 100644 --- a/tests/settings.py +++ b/tests/settings.py @@ -7,15 +7,15 @@ TEMPLATE_DEBUG = DEBUG @@ -42,7 +42,7 @@ SECRET_KEY = 'fn)t*+$)ugeyip6-#txyy$5wf2ervc0d2n#h)qb)y5@ly$t*@w' INSTALLED_APPS = ( -@@ -52,6 +52,8 @@ MEDIA_URL = '/media/' +@@ -72,6 +72,8 @@ MEDIA_URL = '/media/' STATIC_ROOT = '%s/static/' % SITE_ROOT STATIC_URL = '/static/' diff -Nru djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/PKG-INFO djangorestframework-gis-0.11/djangorestframework_gis.egg-info/PKG-INFO --- djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/PKG-INFO 2016-01-06 12:19:25.000000000 +0000 +++ djangorestframework-gis-0.11/djangorestframework_gis.egg-info/PKG-INFO 2016-11-22 12:28:37.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: djangorestframework-gis -Version: 0.10.1 +Version: 0.11 Summary: Geographic add-ons for Django Rest Framework Home-page: https://github.com/djangonauts/django-rest-framework-gis Author: Douglas Meehan diff -Nru djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/requires.txt djangorestframework-gis-0.11/djangorestframework_gis.egg-info/requires.txt --- djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/requires.txt 2016-01-06 12:19:25.000000000 +0000 +++ djangorestframework-gis-0.11/djangorestframework_gis.egg-info/requires.txt 2016-11-22 12:28:37.000000000 +0000 @@ -1 +1 @@ -djangorestframework>=3.3 +djangorestframework>=3.3,<3.6 diff -Nru djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/SOURCES.txt djangorestframework-gis-0.11/djangorestframework_gis.egg-info/SOURCES.txt --- djangorestframework-gis-0.10.1/djangorestframework_gis.egg-info/SOURCES.txt 2016-01-06 12:19:25.000000000 +0000 +++ djangorestframework-gis-0.11/djangorestframework_gis.egg-info/SOURCES.txt 2016-11-22 12:28:39.000000000 +0000 @@ -35,4 +35,6 @@ tests/django_restframework_gis_tests/test_performance.py tests/django_restframework_gis_tests/tests.py tests/django_restframework_gis_tests/urls.py -tests/django_restframework_gis_tests/views.py \ No newline at end of file +tests/django_restframework_gis_tests/views.py +tests/django_restframework_gis_tests/migrations/0001_initial.py +tests/django_restframework_gis_tests/migrations/__init__.py \ No newline at end of file diff -Nru djangorestframework-gis-0.10.1/PKG-INFO djangorestframework-gis-0.11/PKG-INFO --- djangorestframework-gis-0.10.1/PKG-INFO 2016-01-06 12:19:25.000000000 +0000 +++ djangorestframework-gis-0.11/PKG-INFO 2016-11-22 12:28:39.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: djangorestframework-gis -Version: 0.10.1 +Version: 0.11 Summary: Geographic add-ons for Django Rest Framework Home-page: https://github.com/djangonauts/django-rest-framework-gis Author: Douglas Meehan diff -Nru djangorestframework-gis-0.10.1/README.rst djangorestframework-gis-0.11/README.rst --- djangorestframework-gis-0.10.1/README.rst 2016-01-06 12:06:45.000000000 +0000 +++ djangorestframework-gis-0.11/README.rst 2016-11-22 12:02:00.000000000 +0000 @@ -1,7 +1,7 @@ django-rest-framework-gis ========================= -|Build Status| |Coverage Status| |Requirements Status| |PyPI version| |PyPI downloads| +|Build Status| |Coverage Status| |Requirements Status| |PyPI version| Geographic add-ons for Django Rest Framework - `Mailing List `__. @@ -39,6 +39,7 @@ =============== ============================ ==================== ================================== DRF-gis version DRF version Django version Python version +**0.11.x** **3.1** to **3.5** **1.7** to **1.10** **2.7** to **3.5** **0.10.x** **3.1** to **3.3** **1.7** to **1.9** **2.7** to **3.5** **0.9.6** **3.1** to **3.2** **1.5** to **1.8** **2.6** to **3.5** **0.9.5** **3.1** to **3.2** **1.5** to **1.8** **2.6** to **3.4** @@ -341,7 +342,7 @@ Metadata is stored in a PostgreSQL HStore field, which allows us to store arbitrary key-value pairs with a link record. """ - metadata = HStoreField(blank=True, null=True, default={}) + metadata = HStoreField(blank=True, null=True, default=dict) geo = models.LineStringField() objects = models.GeoManager() @@ -428,6 +429,10 @@ Filters ------- +**note**: this feature is compatible with django-filter up to version 0.15. +If you need compatibility with version django-filter 1.0 please send a patch +(see `issue #120 `_). + We provide a ``GeometryFilter`` field as well as a ``GeoFilterSet`` for usage with ``django_filter``. You simply provide, in the query string, one of the textual types supported by ``GEOSGeometry``. By @@ -625,5 +630,3 @@ :target: https://requires.io/github/djangonauts/django-rest-framework-gis/requirements/?branch=master .. |PyPI version| image:: https://badge.fury.io/py/djangorestframework-gis.svg :target: http://badge.fury.io/py/djangorestframework-gis -.. |PyPI downloads| image:: https://img.shields.io/pypi/dm/djangorestframework-gis.svg - :target: http://badge.fury.io/py/djangorestframework-gis diff -Nru djangorestframework-gis-0.10.1/requirements.txt djangorestframework-gis-0.11/requirements.txt --- djangorestframework-gis-0.10.1/requirements.txt 2016-01-06 12:01:58.000000000 +0000 +++ djangorestframework-gis-0.11/requirements.txt 2016-11-22 12:02:00.000000000 +0000 @@ -1 +1 @@ -djangorestframework>=3.3 +djangorestframework>=3.3,<3.6 diff -Nru djangorestframework-gis-0.10.1/rest_framework_gis/filters.py djangorestframework-gis-0.11/rest_framework_gis/filters.py --- djangorestframework-gis-0.10.1/rest_framework_gis/filters.py 2015-07-17 17:12:21.000000000 +0000 +++ djangorestframework-gis-0.11/rest_framework_gis/filters.py 2016-11-22 11:54:54.000000000 +0000 @@ -84,7 +84,11 @@ } def __new__(cls, *args, **kwargs): - cls.filter_overrides.update(cls.GEOFILTER_FOR_DBFIELD_DEFAULTS) + try: + cls._meta.filter_overrides.update(cls.GEOFILTER_FOR_DBFIELD_DEFAULTS) + # maintain compatibility for django-filter < 0.15 + except AttributeError: # pragma: nocover + cls.filter_overrides.update(cls.GEOFILTER_FOR_DBFIELD_DEFAULTS) cls.LOOKUP_TYPES = sorted(gis_lookups) return super(GeoFilterSet, cls).__new__(cls) diff -Nru djangorestframework-gis-0.10.1/rest_framework_gis/__init__.py djangorestframework-gis-0.11/rest_framework_gis/__init__.py --- djangorestframework-gis-0.10.1/rest_framework_gis/__init__.py 2016-01-06 12:06:32.000000000 +0000 +++ djangorestframework-gis-0.11/rest_framework_gis/__init__.py 2016-11-22 12:22:09.000000000 +0000 @@ -1,4 +1,4 @@ -VERSION = (0, 10, 1, 'final') +VERSION = (0, 11, 0, 'final') __version__ = VERSION # alias diff -Nru djangorestframework-gis-0.10.1/setup.cfg djangorestframework-gis-0.11/setup.cfg --- djangorestframework-gis-0.10.1/setup.cfg 2016-01-06 12:19:25.000000000 +0000 +++ djangorestframework-gis-0.11/setup.cfg 2016-11-22 12:28:39.000000000 +0000 @@ -2,7 +2,7 @@ universal = 1 [egg_info] -tag_build = tag_date = 0 tag_svn_revision = 0 +tag_build = diff -Nru djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/migrations/0001_initial.py djangorestframework-gis-0.11/tests/django_restframework_gis_tests/migrations/0001_initial.py --- djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/migrations/0001_initial.py 1970-01-01 00:00:00.000000000 +0000 +++ djangorestframework-gis-0.11/tests/django_restframework_gis_tests/migrations/0001_initial.py 2016-04-04 08:25:41.000000000 +0000 @@ -0,0 +1,58 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.9.4 on 2016-04-01 17:00 +from __future__ import unicode_literals + +import django.contrib.gis.db.models.fields +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='BoxedLocation', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(max_length=32)), + ('slug', models.SlugField(blank=True, max_length=128, unique=True)), + ('timestamp', models.DateTimeField(blank=True, null=True)), + ('geometry', django.contrib.gis.db.models.fields.GeometryField(srid=4326)), + ('bbox_geometry', django.contrib.gis.db.models.fields.PolygonField(srid=4326)), + ], + options={ + 'abstract': False, + }, + ), + migrations.CreateModel( + name='LocatedFile', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(max_length=32)), + ('slug', models.SlugField(blank=True, max_length=128, unique=True)), + ('timestamp', models.DateTimeField(blank=True, null=True)), + ('geometry', django.contrib.gis.db.models.fields.GeometryField(srid=4326)), + ('file', models.FileField(blank=True, null=True, upload_to='located_files')), + ], + options={ + 'abstract': False, + }, + ), + migrations.CreateModel( + name='Location', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(max_length=32)), + ('slug', models.SlugField(blank=True, max_length=128, unique=True)), + ('timestamp', models.DateTimeField(blank=True, null=True)), + ('geometry', django.contrib.gis.db.models.fields.GeometryField(srid=4326)), + ], + options={ + 'abstract': False, + }, + ), + ] diff -Nru djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/serializers.py djangorestframework-gis-0.11/tests/django_restframework_gis_tests/serializers.py --- djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/serializers.py 2015-10-29 09:33:04.000000000 +0000 +++ djangorestframework-gis-0.11/tests/django_restframework_gis_tests/serializers.py 2016-11-22 11:54:54.000000000 +0000 @@ -27,6 +27,7 @@ class Meta: model = Location + exclude = [] class PaginatedLocationGeoSerializer(pagination.PageNumberPagination): @@ -46,6 +47,7 @@ class Meta: model = Location geo_field = 'geometry' + exclude = [] class LocationGeoFeatureSlugSerializer(LocationGeoFeatureSerializer): @@ -63,6 +65,7 @@ model = Location geo_field = 'geometry' id_field = False + exclude = [] class LocationGeoFeatureNoIdSerializer(LocationGeoFeatureSerializer): @@ -88,6 +91,7 @@ class Meta: model = Location geo_field = 'geometry' + exclude = [] class BoxedLocationGeoFeatureSerializer(gis_serializers.GeoFeatureModelSerializer): @@ -106,6 +110,7 @@ model = Location geo_field = 'geometry' auto_bbox = True + exclude = [] class LocationGeoFeatureMethodSerializer(gis_serializers.GeoFeatureModelSerializer): @@ -120,6 +125,7 @@ class Meta: model = Location geo_field = 'new_geometry' + exclude = [] class NoneGeoFeatureMethodSerializer(gis_serializers.GeoFeatureModelSerializer): diff -Nru djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/tests.py djangorestframework-gis-0.11/tests/django_restframework_gis_tests/tests.py --- djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/tests.py 2015-10-29 09:33:04.000000000 +0000 +++ djangorestframework-gis-0.11/tests/django_restframework_gis_tests/tests.py 2016-04-01 16:38:52.000000000 +0000 @@ -5,6 +5,7 @@ import urllib import sys import json +import pickle from django.test import TestCase from django.contrib.gis.geos import GEOSGeometry, Polygon, Point @@ -12,6 +13,7 @@ from django.core.exceptions import ImproperlyConfigured from rest_framework_gis import serializers as gis_serializers +from rest_framework_gis.fields import GeoJsonDict from .models import Location, LocatedFile from .serializers import LocationGeoSerializer @@ -570,8 +572,6 @@ self.assertIn('previous', response.data) def test_pickle(self): - import pickle - from rest_framework_gis.fields import GeoJsonDict geometry = GEOSGeometry('POINT (30 10)') geojsondict = GeoJsonDict(( ('type', geometry.geom_type), diff -Nru djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/urls.py djangorestframework-gis-0.11/tests/django_restframework_gis_tests/urls.py --- djangorestframework-gis-0.10.1/tests/django_restframework_gis_tests/urls.py 2015-10-20 09:40:28.000000000 +0000 +++ djangorestframework-gis-0.11/tests/django_restframework_gis_tests/urls.py 2016-04-13 07:49:11.000000000 +0000 @@ -1,35 +1,92 @@ -from django.conf.urls import patterns, url +from django.conf.urls import url +from . import views - -urlpatterns = patterns('django_restframework_gis_tests.views', - url(r'^$', 'location_list', name='api_location_list'), - url(r'^(?P[0-9]+)/$', 'location_details', name='api_location_details'), +urlpatterns = [ + url(r'^$', views.location_list, name='api_location_list'), + url( + r'^(?P[0-9]+)/$', + views.location_details, + name='api_location_details'), # geojson - url(r'^geojson/$', 'geojson_location_list', name='api_geojson_location_list'), - url(r'^geojson/(?P[0-9]+)/$', 'geojson_location_details', name='api_geojson_location_details'), - url(r'^geojson_hidden/(?P[0-9]+)/$', 'geojson_location_details_hidden', name='api_geojson_location_details_hidden'), - url(r'^geojson_none/(?P[0-9]+)/$', 'geojson_location_details_none', name='api_geojson_location_details_none'), - url(r'^geojson/(?P[-\w]+)/$', 'geojson_location_slug_details', name='api_geojson_location_slug_details'), - url(r'^geojson-falseid/(?P[0-9]+)/$', 'geojson_location_falseid_details', name='api_geojson_location_falseid_details'), - url(r'^geojson-noid/(?P[0-9]+)/$', 'geojson_location_noid_details', name='api_geojson_location_noid_details'), + url( + r'^geojson/$', + views.geojson_location_list, + name='api_geojson_location_list'), + url( + r'^geojson/(?P[0-9]+)/$', + views.geojson_location_details, + name='api_geojson_location_details'), + url( + r'^geojson_hidden/(?P[0-9]+)/$', + views.geojson_location_details_hidden, + name='api_geojson_location_details_hidden'), + url( + r'^geojson_none/(?P[0-9]+)/$', + views.geojson_location_details_none, + name='api_geojson_location_details_none'), + url( + r'^geojson/(?P[-\w]+)/$', + views.geojson_location_slug_details, + name='api_geojson_location_slug_details'), + url( + r'^geojson-falseid/(?P[0-9]+)/$', + views.geojson_location_falseid_details, + name='api_geojson_location_falseid_details'), + url( + r'^geojson-noid/(?P[0-9]+)/$', + views.geojson_location_noid_details, + name='api_geojson_location_noid_details'), # file - url(r'^geojson-file/(?P[0-9]+)/$', 'geojson_located_file_details', name='api_geojson_located_file_details'), + url( + r'^geojson-file/(?P[0-9]+)/$', + views.geojson_located_file_details, + name='api_geojson_located_file_details'), # geojson with bbox with its own geometry field - url(r'^geojson-with-bbox/$', 'geojson_boxedlocation_list', name='api_geojson_boxedlocation_list'), - url(r'^geojson-with-bbox/(?P[0-9]+)/$', 'geojson_boxedlocation_details', name='api_geojson_boxedlocation_details'), + url( + r'^geojson-with-bbox/$', + views.geojson_boxedlocation_list, + name='api_geojson_boxedlocation_list'), + url( + r'^geojson-with-bbox/(?P[0-9]+)/$', + views.geojson_boxedlocation_details, + name='api_geojson_boxedlocation_details'), # geojson with bbox with autogenerated bbox - url(r'^geojson-with-auto-bbox/$', 'geojson_location_bbox_list', name='api_geojson_location_bbox_list'), + url( + r'^geojson-with-auto-bbox/$', + views.geojson_location_bbox_list, + name='api_geojson_location_bbox_list'), # Filters - url(r'^filters/contained_in_bbox$', 'geojson_location_contained_in_bbox_list', name='api_geojson_location_list_contained_in_bbox_filter'), - url(r'^filters/overlaps_bbox$', 'geojson_location_overlaps_bbox_list', name='api_geojson_location_list_overlaps_bbox_filter'), - url(r'^filters/contained_in_geometry$', 'geojson_contained_in_geometry', name='api_geojson_contained_in_geometry'), - url(r'^filters/contained_in_tile$', 'geojson_location_contained_in_tile_list', name='api_geojson_location_list_contained_in_tile_filter'), - url(r'^filters/overlaps_tile$', 'geojson_location_overlaps_tile_list', name='api_geojson_location_list_overlaps_tile_filter'), - url(r'^filters/within_distance_of_point$', 'geojson_location_within_distance_of_point_list', name='api_geojson_location_list_within_distance_of_point_filter'), - url(r'^filters/within_degrees_of_point$', 'geojson_location_within_degrees_of_point_list', name='api_geojson_location_list_within_degrees_of_point_filter'), -) + url( + r'^filters/contained_in_bbox$', + views.geojson_location_contained_in_bbox_list, + name='api_geojson_location_list_contained_in_bbox_filter'), + url( + r'^filters/overlaps_bbox$', + views.geojson_location_overlaps_bbox_list, + name='api_geojson_location_list_overlaps_bbox_filter'), + url( + r'^filters/contained_in_geometry$', + views.geojson_contained_in_geometry, + name='api_geojson_contained_in_geometry'), + url( + r'^filters/contained_in_tile$', + views.geojson_location_contained_in_tile_list, + name='api_geojson_location_list_contained_in_tile_filter'), + url( + r'^filters/overlaps_tile$', + views.geojson_location_overlaps_tile_list, + name='api_geojson_location_list_overlaps_tile_filter'), + url( + r'^filters/within_distance_of_point$', + views.geojson_location_within_distance_of_point_list, + name='api_geojson_location_list_within_distance_of_point_filter'), + url( + r'^filters/within_degrees_of_point$', + views.geojson_location_within_degrees_of_point_list, + name='api_geojson_location_list_within_degrees_of_point_filter'), +] diff -Nru djangorestframework-gis-0.10.1/tests/local_settings.py djangorestframework-gis-0.11/tests/local_settings.py --- djangorestframework-gis-0.10.1/tests/local_settings.py 2015-09-27 18:03:14.000000000 +0000 +++ djangorestframework-gis-0.11/tests/local_settings.py 2016-11-22 11:07:55.000000000 +0000 @@ -39,6 +39,7 @@ ) POSTGIS_VERSION = (2, 1) +GDAL_LIBRARY_PATH = '/usr/lib/libgdal.so.1' #REST_FRAMEWORK = { # 'DEFAULT_RENDERER_CLASSES': ( diff -Nru djangorestframework-gis-0.10.1/tests/settings.py djangorestframework-gis-0.11/tests/settings.py --- djangorestframework-gis-0.10.1/tests/settings.py 2015-08-24 15:58:25.000000000 +0000 +++ djangorestframework-gis-0.11/tests/settings.py 2016-04-13 08:00:12.000000000 +0000 @@ -35,8 +35,28 @@ ) MIDDLEWARE_CLASSES = [ + 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', + 'django.contrib.auth.middleware.AuthenticationMiddleware', + 'django.contrib.messages.middleware.MessageMiddleware', + 'django.middleware.clickjacking.XFrameOptionsMiddleware', +] + +TEMPLATES = [ + { + 'BACKEND': 'django.template.backends.django.DjangoTemplates', + 'DIRS': [], + 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.template.context_processors.debug', + 'django.template.context_processors.request', + 'django.contrib.auth.context_processors.auth', + 'django.contrib.messages.context_processors.messages', + ], + }, + }, ] ROOT_URLCONF = 'urls' diff -Nru djangorestframework-gis-0.10.1/tests/urls.py djangorestframework-gis-0.11/tests/urls.py --- djangorestframework-gis-0.10.1/tests/urls.py 2016-01-06 12:01:58.000000000 +0000 +++ djangorestframework-gis-0.11/tests/urls.py 2016-04-13 07:49:11.000000000 +0000 @@ -1,8 +1,6 @@ from django.conf.urls import include, url from django.contrib import admin - -admin.autodiscover() - +from django.contrib.staticfiles import views urlpatterns = [ # Uncomment the next line to enable the admin: @@ -12,6 +10,6 @@ url(r'', include('django_restframework_gis_tests.urls')), - url(r'^static/(?P.*)$', 'django.contrib.staticfiles.views.serve'), + url(r'^static/(?P.*)$', views.serve), ]