[python-django-tagging/f19] use builtin next(i) instead of i.next() for compatibility with Py3

Jakub QB Dorňák jdornak at fedoraproject.org
Mon Dec 23 14:13:39 UTC 2013


commit 0d260fdc1daea1137024bcd9be825d7d449f8e03
Author: Jakub Dorňák <jdornak at redhat.com>
Date:   Mon Dec 23 15:13:20 2013 +0100

    use builtin next(i) instead of i.next() for compatibility with Py3

 python-django-tagging-0.3.1-utils-python3.patch |   25 +++++++++++++++++++++-
 python-django-tagging.spec                      |    5 +++-
 2 files changed, 27 insertions(+), 3 deletions(-)
---
diff --git a/python-django-tagging-0.3.1-utils-python3.patch b/python-django-tagging-0.3.1-utils-python3.patch
index 97fa667..dfe25eb 100644
--- a/python-django-tagging-0.3.1-utils-python3.patch
+++ b/python-django-tagging-0.3.1-utils-python3.patch
@@ -1,5 +1,5 @@
---- django-tagging-0.3.1/tagging/utils.py.orig	2013-12-05 14:45:26.931702819 +0100
-+++ django-tagging-0.3.1/tagging/utils.py	2013-12-05 14:46:15.896743894 +0100
+--- django-tagging-0.3.1/tagging/utils.py.orig	2013-12-23 14:59:40.983586230 +0100
++++ django-tagging-0.3.1/tagging/utils.py	2013-12-23 15:01:50.657281603 +0100
 @@ -3,7 +3,10 @@ Tagging utilities - from user tag input
  calculation.
  """
@@ -12,6 +12,27 @@
  
  from django.db.models.query import QuerySet
  try:
+@@ -50,17 +53,17 @@ def parse_tag_input(input):
+     i = iter(input)
+     try:
+         while 1:
+-            c = i.next()
++            c = next(i)
+             if c == u'"':
+                 if buffer:
+                     to_be_split.append(u''.join(buffer))
+                     buffer = []
+                 # Find the matching quote
+                 open_quote = True
+-                c = i.next()
++                c = next(i)
+                 while c != u'"':
+                     buffer.append(c)
+-                    c = i.next()
++                    c = next(i)
+                 if buffer:
+                     word = u''.join(buffer).strip()
+                     if word:
 @@ -168,18 +171,18 @@ def get_tag_list(tags):
          return [tags]
      elif isinstance(tags, QuerySet) and tags.model is Tag:
diff --git a/python-django-tagging.spec b/python-django-tagging.spec
index 9d7eed5..00becd6 100644
--- a/python-django-tagging.spec
+++ b/python-django-tagging.spec
@@ -3,7 +3,7 @@
 %global pkgname django-tagging
 Name:           python-django-tagging
 Version:        0.3.1
-Release:        9%{?dist}
+Release:        11%{?dist}
 Summary:        A generic tagging application for Django projects
 
 Group:          Development/Languages
@@ -91,6 +91,9 @@ popd
 
 
 %changelog
+* Mon Dec 23 2013 Jakub Dorňák <jdornak at redhat.com> - 0.3.1-11
+- use builtin next(i) instead of i.next() for compatibility with Py3
+
 * Thu Dec  5 2013 Jakub Dorňák <jdornak at redhat.com> - 0.3.1-9
 - fixed use of types which are not available in Py3
 


More information about the scm-commits mailing list