aboutsummaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorRaphaël Hertzog <hertzog@debian.org>2014-02-14 09:31:36 +0100
committerRaphaël Hertzog <hertzog@debian.org>2014-02-14 09:31:36 +0100
commit12e3089483edada047fc98600344a83333132aef (patch)
treee189c6c956cbce15db056677967e631197806361 /debian
parent81b6abeb2de5ce6cfd4d4d69fe0c9f20a96fd1c7 (diff)
parentc1ee6e25da23b79b404a8a5cc61666d532d385f0 (diff)
downloadpython-django-tagging-12e3089483edada047fc98600344a83333132aef.tar
python-django-tagging-12e3089483edada047fc98600344a83333132aef.tar.gz
Imported Debian patch 1:0.3.1-4
Diffstat (limited to 'debian')
-rw-r--r--debian/changelog11
-rw-r--r--debian/compat2
-rw-r--r--debian/control6
-rw-r--r--debian/patches/django-1.7-compat.patch37
-rw-r--r--debian/patches/fix-testsuite.patch39
-rw-r--r--debian/patches/series2
-rwxr-xr-xdebian/rules3
7 files changed, 96 insertions, 4 deletions
diff --git a/debian/changelog b/debian/changelog
index fde5450..3ad84d6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,14 @@
+python-django-tagging (1:0.3.1-4) unstable; urgency=medium
+
+ * Drop David Spreen from Uploaders. Closes: #738932
+ * Add fix-testsuite.patch and now run the testsuite.
+ * Add django-1.7-compat.patch to make it work with Django 1.7.
+ Closes: #755624
+ * Bump Standards-Version to 3.9.5 and debhelper compat to 9.
+ * Add python-django to Build-Depends for the test suite.
+
+ -- Raphaël Hertzog <hertzog@debian.org> Fri, 14 Feb 2014 09:31:36 +0100
+
python-django-tagging (1:0.3.1-3) unstable; urgency=low
[ Jakub Wilk ]
diff --git a/debian/compat b/debian/compat
index 45a4fb7..ec63514 100644
--- a/debian/compat
+++ b/debian/compat
@@ -1 +1 @@
-8
+9
diff --git a/debian/control b/debian/control
index c7ed371..8f7f069 100644
--- a/debian/control
+++ b/debian/control
@@ -2,9 +2,9 @@ Source: python-django-tagging
Section: python
Priority: optional
Maintainer: Debian Python Modules Team <python-modules-team@lists.alioth.debian.org>
-Uploaders: Raphaël Hertzog <hertzog@debian.org>, David Spreen <netzwurm@debian.org>, Jonas Genannt <jonas.genannt@capi2name.de>
-Standards-Version: 3.9.4
-Build-Depends: debhelper (>= 8), python (>= 2.6.6-3~)
+Uploaders: Raphaël Hertzog <hertzog@debian.org>, Jonas Genannt <jonas.genannt@capi2name.de>
+Standards-Version: 3.9.5
+Build-Depends: debhelper (>= 9), python (>= 2.6.6-3~), python-django
Build-Depends-Indep: python-docutils
Vcs-Svn: svn://anonscm.debian.org/python-modules/packages/python-django-tagging/trunk/
Vcs-Browser: http://anonscm.debian.org/viewvc/python-modules/packages/python-django-tagging/trunk/
diff --git a/debian/patches/django-1.7-compat.patch b/debian/patches/django-1.7-compat.patch
new file mode 100644
index 0000000..4e50ffe
--- /dev/null
+++ b/debian/patches/django-1.7-compat.patch
@@ -0,0 +1,37 @@
+Description: Add django 1.7 compatibility
+Author: Raphaël Hertzog <hertzog@debian.org>
+Bug-Debian: http://bugs.debian.org/755624
+Origin: vendor
+Last-Update: 2014-08-06
+
+--- python-django-tagging-0.3.1.orig/tagging/models.py
++++ python-django-tagging-0.3.1/tagging/models.py
+@@ -17,6 +17,8 @@ from tagging import settings
+ from tagging.utils import calculate_cloud, get_tag_list, get_queryset_and_model, parse_tag_input
+ from tagging.utils import LOGARITHMIC
+
++import collections
++
+ qn = connection.ops.quote_name
+
+ ############
+@@ -166,9 +168,16 @@ class TagManager(models.Manager):
+ # Django 1.2+
+ compiler = queryset.query.get_compiler(using='default')
+ extra_joins = ' '.join(compiler.get_from_clause()[0][1:])
+- where, params = queryset.query.where.as_sql(
+- compiler.quote_name_unless_alias, compiler.connection
+- )
++ if isinstance(compiler, collections.Callable):
++ # Django 1.7+
++ where, params = queryset.query.where.as_sql(
++ compiler, compiler.connection
++ )
++ else:
++ # Django 1.2-1.6
++ where, params = queryset.query.where.as_sql(
++ compiler.quote_name_unless_alias, compiler.connection
++ )
+ else:
+ # Django pre-1.2
+ extra_joins = ' '.join(queryset.query.get_from_clause()[0][1:])
diff --git a/debian/patches/fix-testsuite.patch b/debian/patches/fix-testsuite.patch
new file mode 100644
index 0000000..11de6c2
--- /dev/null
+++ b/debian/patches/fix-testsuite.patch
@@ -0,0 +1,39 @@
+Description: Fix settings for test suite
+Author: Raphaël Hertzog <hertzog@debian.org>
+Origin: vendor
+
+---
+The information above should follow the Patch Tagging Guidelines, please
+checkout http://dep.debian.net/deps/dep3/ to learn about the format.
+--- python-django-tagging-0.3.1.orig/tagging/tests/settings.py
++++ python-django-tagging-0.3.1/tagging/tests/settings.py
+@@ -3,22 +3,14 @@ DIRNAME = os.path.dirname(__file__)
+
+ DEFAULT_CHARSET = 'utf-8'
+
+-test_engine = os.environ.get("TAGGING_TEST_ENGINE", "sqlite3")
+-
+-DATABASE_ENGINE = test_engine
+-DATABASE_NAME = os.environ.get("TAGGING_DATABASE_NAME", "tagging_test")
+-DATABASE_USER = os.environ.get("TAGGING_DATABASE_USER", "")
+-DATABASE_PASSWORD = os.environ.get("TAGGING_DATABASE_PASSWORD", "")
+-DATABASE_HOST = os.environ.get("TAGGING_DATABASE_HOST", "localhost")
+-
+-if test_engine == "sqlite":
+- DATABASE_NAME = os.path.join(DIRNAME, 'tagging_test.db')
+- DATABASE_HOST = ""
+-elif test_engine == "mysql":
+- DATABASE_PORT = os.environ.get("TAGGING_DATABASE_PORT", 3306)
+-elif test_engine == "postgresql_psycopg2":
+- DATABASE_PORT = os.environ.get("TAGGING_DATABASE_PORT", 5432)
++DATABASES = {
++ 'default': {
++ 'ENGINE': 'django.db.backends.sqlite3',
++ 'NAME': os.path.join(DIRNAME, 'tagging_test.db'),
++ }
++}
+
++SECRET_KEY = 'liewoo1jie7TahTao3ci7xayee8gieg9ukee'
+
+ INSTALLED_APPS = (
+ 'django.contrib.contenttypes',
diff --git a/debian/patches/series b/debian/patches/series
index 4753ab0..5499ba6 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,3 @@
fix_calc_tag_weight
+fix-testsuite.patch
+django-1.7-compat.patch
diff --git a/debian/rules b/debian/rules
index fce3faa..b76798a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,6 +5,9 @@ PKG = $(shell dh_listpackages)
%:
dh $@ --with python2
+override_dh_auto_test:
+ PYTHONPATH=. DJANGO_SETTINGS_MODULE=tagging.tests.settings python /usr/bin/django-admin test
+
override_dh_installdocs:
dh_installdocs
# Generate documentation