[Python-modules-commits] r24934 - in packages/geopy/trunk/debian (5 files)
eriol-guest at users.alioth.debian.org
eriol-guest at users.alioth.debian.org
Mon Jun 24 13:00:56 UTC 2013
Date: Monday, June 24, 2013 @ 13:00:52
Author: eriol-guest
Revision: 24934
Use __lt__() and __eq__() instead of __cmp__() and cmp()
Added:
packages/geopy/trunk/debian/patches/04_use_lt_and_eq_instead_of_cmp.patch
Modified:
packages/geopy/trunk/debian/changelog
packages/geopy/trunk/debian/patches/02_fix_missing_imports.patch
packages/geopy/trunk/debian/patches/03_fix_typo.patch
packages/geopy/trunk/debian/patches/series
Modified: packages/geopy/trunk/debian/changelog
===================================================================
--- packages/geopy/trunk/debian/changelog 2013-06-24 12:10:44 UTC (rev 24933)
+++ packages/geopy/trunk/debian/changelog 2013-06-24 13:00:52 UTC (rev 24934)
@@ -21,10 +21,12 @@
- Fix missing imports
* debian/patches/03_fix_typo.patch
- Fix some typos
+ * debian/patches/04_use_lt_and_eq_instead_of_cmp.patch
+ - Use __lt__() and __eq__() instead of __cmp__() and cmp()
* debian/rules
- Reworked for Python3 package
- -- Daniele Tricoli <eriol at mornie.org> Mon, 24 Jun 2013 01:45:51 +0200
+ -- Daniele Tricoli <eriol at mornie.org> Mon, 24 Jun 2013 14:59:34 +0200
geopy (0.94.2-1) unstable; urgency=low
Modified: packages/geopy/trunk/debian/patches/02_fix_missing_imports.patch
===================================================================
--- packages/geopy/trunk/debian/patches/02_fix_missing_imports.patch 2013-06-24 12:10:44 UTC (rev 24933)
+++ packages/geopy/trunk/debian/patches/02_fix_missing_imports.patch 2013-06-24 13:00:52 UTC (rev 24934)
@@ -1,6 +1,6 @@
-Description: Fix missing imports.
+Description: Fix missing imports
Author: Daniele Tricoli <eriol at mornie.org>
-Last-Update: 2013-06-13
+Last-Update: 2013-06-23
--- a/geopy/geocoders/wiki_gis.py
+++ b/geopy/geocoders/wiki_gis.py
Modified: packages/geopy/trunk/debian/patches/03_fix_typo.patch
===================================================================
--- packages/geopy/trunk/debian/patches/03_fix_typo.patch 2013-06-24 12:10:44 UTC (rev 24933)
+++ packages/geopy/trunk/debian/patches/03_fix_typo.patch 2013-06-24 13:00:52 UTC (rev 24934)
@@ -1,6 +1,6 @@
-Description: Fix typos.
+Description: Fix typos
Author: Daniele Tricoli <eriol at mornie.org>
-Last-Update: 2013-06-13
+Last-Update: 2013-06-23
--- a/geopy/geocoders/wiki_semantic.py
+++ b/geopy/geocoders/wiki_semantic.py
Added: packages/geopy/trunk/debian/patches/04_use_lt_and_eq_instead_of_cmp.patch
===================================================================
--- packages/geopy/trunk/debian/patches/04_use_lt_and_eq_instead_of_cmp.patch (rev 0)
+++ packages/geopy/trunk/debian/patches/04_use_lt_and_eq_instead_of_cmp.patch 2013-06-24 13:00:52 UTC (rev 24934)
@@ -0,0 +1,27 @@
+Description: Use __lt__() and __eq__() instead of __cmp__() and cmp()
+Author: Daniele Tricoli <eriol at mornie.org>
+Last-Update: 2013-06-24
+
+--- a/geopy/distance.py
++++ b/geopy/distance.py
+@@ -77,11 +77,17 @@
+ def __str__(self):
+ return '%s km' % self.__kilometers
+
+- def __cmp__(self, other):
++ def __lt__(self, other):
+ if isinstance(other, Distance):
+- return cmp(self.kilometers, other.kilometers)
++ return self.kilometers < other.kilometers
+ else:
+- return cmp(self.kilometers, other)
++ return self.kilometers < other
++
++ def __eq__(self, other):
++ if isinstance(other, Distance):
++ return self.kilometers == other.kilometers
++ else:
++ return self.kilometers == other
+
+ @property
+ def kilometers(self):
Modified: packages/geopy/trunk/debian/patches/series
===================================================================
--- packages/geopy/trunk/debian/patches/series 2013-06-24 12:10:44 UTC (rev 24933)
+++ packages/geopy/trunk/debian/patches/series 2013-06-24 13:00:52 UTC (rev 24934)
@@ -1,3 +1,4 @@
01_add_missing_test_file.patch
02_fix_missing_imports.patch
03_fix_typo.patch
+04_use_lt_and_eq_instead_of_cmp.patch
More information about the Python-modules-commits
mailing list