diff -u snowballz-0.9.5.1/debian/changelog snowballz-0.9.5.1/debian/changelog --- snowballz-0.9.5.1/debian/changelog +++ snowballz-0.9.5.1/debian/changelog @@ -1,3 +1,11 @@ +snowballz (0.9.5.1-2ubuntu1) lucid; urgency=low + + * debian/patches/list_nohash.patch: + - catch a case where the cellulose celltype tries to get variables + from None types (LP: #350466, #234598) + + -- Niall Creech Sat, 20 Feb 2010 15:47:12 +0000 + snowballz (0.9.5.1-2) unstable; urgency=low [ Barry deFreese ] 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 +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) + +