hello,

Thank you for your patch; we encountered the same problem for making 
logilab-common Py3k compatible.

On Saturday 18 September 2010 23:41:48 Arfrever Frehtes Taifersar Arahesis 
wrote:


> logilab-common-0.51.1-python-2.7.patch
>   --- testlib.py
> +++ testlib.py
> @@ -1022,8 +1022,12 @@
>  
>      def __init__(self, methodName='runTest'):
>          super(TestCase, self).__init__(methodName)
> +        # internal API changed in python2.7
> +        if sys.version_info >= (2, 7):
> +            self.__exc_info = sys.exc_info
> +            self.__testMethodName = self._testMethodName
>          # internal API changed in python2.5
> -        if sys.version_info >= (2, 5):
> +        elif sys.version_info >= (2, 5):
>              self.__exc_info = self._exc_info
>              self.__testMethodName = self._testMethodName
>          else:

We can just do :

-            self.__exc_info = self._exc_info
+            self.__exc_info = sys.exc_info

since _exc_info is doing nothing else.

-- 

Emile Anclin <[email protected]>
http://www.logilab.fr/   http://www.logilab.org/ 
Informatique scientifique & et gestion de connaissances
_______________________________________________
Python-Projects mailing list
[email protected]
http://lists.logilab.org/mailman/listinfo/python-projects

Reply via email to