Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/www/py-django-taggit Allow Python 2.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/14d2e266a923
branches:  trunk
changeset: 436903:14d2e266a923
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Tue Aug 11 18:41:26 2020 +0000

description:
Allow Python 2.

diffstat:

 www/py-django-taggit/distinfo                         |   3 +-
 www/py-django-taggit/patches/patch-taggit_managers.py |  22 +++++++++++++++++++
 2 files changed, 24 insertions(+), 1 deletions(-)

diffs (38 lines):

diff -r c49d71610c69 -r 14d2e266a923 www/py-django-taggit/distinfo
--- a/www/py-django-taggit/distinfo     Tue Aug 11 18:40:45 2020 +0000
+++ b/www/py-django-taggit/distinfo     Tue Aug 11 18:41:26 2020 +0000
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.1 2020/08/04 00:10:11 joerg Exp $
+$NetBSD: distinfo,v 1.2 2020/08/11 18:41:26 joerg Exp $
 
 SHA1 (django-taggit-1.3.0.tar.gz) = 15ad69a103fddfab618acfcadf15cc80e9b87451
 RMD160 (django-taggit-1.3.0.tar.gz) = c94b2da63aafe97bf5cb756a672bf20776b7182c
 SHA512 (django-taggit-1.3.0.tar.gz) = b78e6bc271f0a6874ee2bccb7f81b0e237096474a19fbf02c77ff5e43dd78e761a9c250c93888c9c739e74d3c0032cc292c53674a3fde918c1882355625e7b77
 Size (django-taggit-1.3.0.tar.gz) = 45355 bytes
+SHA1 (patch-taggit_managers.py) = 1559290b26c15e74cf3aed0bc3a1f1f33e161f6c
diff -r c49d71610c69 -r 14d2e266a923 www/py-django-taggit/patches/patch-taggit_managers.py
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/www/py-django-taggit/patches/patch-taggit_managers.py     Tue Aug 11 18:41:26 2020 +0000
@@ -0,0 +1,22 @@
+$NetBSD: patch-taggit_managers.py,v 1.1 2020/08/11 18:41:26 joerg Exp $
+
+Allow building with Python 2.
+
+--- taggit/managers.py.orig    2020-08-10 00:00:37.878508159 +0000
++++ taggit/managers.py
+@@ -234,11 +234,12 @@ class _TaggableManager(models.Manager):
+ 
+         for new_tag in tags_to_create:
+             if case_insensitive:
+-                lookup = {"name__iexact": new_tag, **tag_kwargs}
++                lookup = {"name__iexact": new_tag}
+             else:
+-                lookup = {"name": new_tag, **tag_kwargs}
++                lookup = {"name": new_tag}
++            lookup.update(tag_kwargs)
+ 
+-            tag, create = manager.get_or_create(**lookup, defaults={"name": new_tag})
++            tag, create = manager.get_or_create(defaults={"name": new_tag}, **lookup)
+             tag_objs.add(tag)
+ 
+         return tag_objs



Home | Main Index | Thread Index | Old Index