On Thu, 09 Aug 2012 12:51:24 +0200, Salvatore Bonaccorso wrote: > I'm no python expert and only did the NMU upload for > nautilus-image-manipulator recently, but I have found that e.g. > google-apps-manager does [1,2] for python2.6 'compatibility': > > [1]: http://code.google.com/p/google-apps-manager/issues/detail?id=61 > [2]: https://code.google.com/p/google-apps-manager/source/detail?r=253# >
Nice, I'm learning something about python by looking at bug reports :) https://code.google.com/p/google-apps-manager/source/diff?spec=svn253&r=253&format=side&path=/trunk/gam.py shows the diff. Let's try: % python2.6 Python 2.6.8 (unknown, Jun 28 2012, 18:14:12) [GCC 4.7.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> sys.version_info (2, 6, 8, 'final', 0) >>> sys.version_info.major Traceback (most recent call last): File "<stdin>", line 1, in <module> AttributeError: 'tuple' object has no attribute 'major' >>> sys.version_info[0] 2 % python2.7 Python 2.7.3rc2 (default, Apr 22 2012, 22:35:38) [GCC 4.6.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> sys.version_info sys.version_info(major=2, minor=7, micro=3, releaselevel='candidate', serial=2) >>> sys.version_info.major 2 >>> sys.version_info[0] 2 % python3.2 Python 3.2.3 (default, Jul 13 2012, 21:02:37) [GCC 4.7.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> sys.version_info sys.version_info(major=3, minor=2, micro=3, releaselevel='final', serial=0) >>> sys.version_info.major 3 >>> sys.version_info[0] 3 Looks like it should work for those "AttributeError: 'tuple' object has no attribute 'major'" bugs. Cheers, gregor -- .''`. Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06 : :' : Debian GNU/Linux user, admin, and developer - http://www.debian.org/ `. `' Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe `- NP: Aimee Mann: Calling It Quits
signature.asc
Description: Digital signature