Package: snowballz Version: 0.9.5.1-2 Severity: wishlist Tags: patch User: ubuntu-de...@lists.ubuntu.com Usertags: origin-ubuntu lucid ubuntu-patch
The below bug doesn't affect debian at the moment but will do if python2.6 is used. This seems to be related to the way __hash__ is implemented in containers, using None type rather than exceptions to mark themselves unhashable. The fix used below should be generally applicable though, it only checks for None types in cellulose celltypes and doesnt try to access variables that wont exist in them *** /tmp/tmp9YCb5W In Ubuntu, we've applied the attached patch to achieve the following: * debian/patches/list_nohash.patch: - catch a case where the cellulose celltype tries to get variables from None types (LP: #350466, #234598) We thought you might be interested in doing the same. -- System Information: Debian Release: squeeze/sid APT prefers lucid APT policy: (500, 'lucid') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-14-generic (SMP w/8 CPU cores) Locale: LANG=en_GB.utf8, LC_CTYPE=en_GB.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash
diff -u snowballz-0.9.5.1/debian/changelog snowballz-0.9.5.1/debian/changelog diff -u snowballz-0.9.5.1/debian/control snowballz-0.9.5.1/debian/control --- snowballz-0.9.5.1/debian/control +++ snowballz-0.9.5.1/debian/control @@ -1,7 +1,8 @@ Source: snowballz Section: games Priority: extra -Maintainer: Debian Games Team <pkg-games-de...@lists.alioth.debian.org> +Maintainer: Ubuntu Developers <ubuntu-devel-disc...@lists.ubuntu.com> +XSBC-Original-Maintainer: Debian Games Team <pkg-games-de...@lists.alioth.debian.org> Uploaders: Miriam Ruiz <little_m...@yahoo.es>, Barry deFreese <bddeb...@comcast.net> Build-Depends: debhelper (>= 5) Build-Depends-Indep: quilt diff -u snowballz-0.9.5.1/debian/patches/series snowballz-0.9.5.1/debian/patches/series --- snowballz-0.9.5.1/debian/patches/series +++ snowballz-0.9.5.1/debian/patches/series @@ -1,0 +2 @@ +list_nohash.patch only in patch2: unchanged: --- snowballz-0.9.5.1.orig/debian/patches/list_nohash.patch +++ snowballz-0.9.5.1/debian/patches/list_nohash.patch @@ -0,0 +1,25 @@ +Subject: Catch a case where the cellulose celltype tries to get variables + from None types. e.g containers that set __hash__= None to disable hashing +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/snowballz/+bug/234598 +Author: Niall Creech <niallcre...@googlemail.com> +Last-Update: 2010-02-20 + +Index: snowballz-0.9.5.1/cellulose/celltypes.py +=================================================================== +--- snowballz-0.9.5.1.orig/cellulose/celltypes.py 2010-02-20 15:37:53.123592334 +0000 ++++ snowballz-0.9.5.1/cellulose/celltypes.py 2010-02-20 15:40:11.280466287 +0000 +@@ -63,9 +63,11 @@ + for name in names: + new = create(name) + old = getattr(cls, name) +- try: new.__name__ = old.__name__ +- except TypeError: pass # __name__ is readonly in python2.3 +- new.__doc__ = old.__doc__ ++ # Handle the None case, __hash__ now returns this in some cases ++ if old != None: ++ try: new.__name__ = old.__name__ ++ except TypeError: pass # __name__ is readonly in python2.3 ++ new.__doc__ = old.__doc__ + setattr(cls, name, new) + +