[apparmor] [patch] parser: make caching tests not fail w/python <= 3.2

Christian Boltz apparmor at cboltz.de
Wed Aug 26 21:44:04 UTC 2015


Hello,

Am Mittwoch, 26. August 2015 schrieb Steve Beattie:
> The following patch creates a new time stamp equality assertion
> function that detects if it's running on python 3.2 or earlier, and
...
> +        if (int(major) <= 3) and (int(minor) <= 2):
> +            self.assertAlmostEquals(time1, time2, places=5)
> +        else:
> +            self.assertEquals(time1, time2)

Just curious - what about Python 2.x? Python 2.7 will hit the "else" 
branch (because minor is > 2), and I'm not sure if that's what you want.

(Assuming we still want to support py2 - I know we do this officially, 
but some code already disagrees ;-) and nobody (except you) complained 
yet.)


Regards,

Christian Boltz
-- 
> Am Besten wäre natürlich, den Owner von /dev/usbkabel ;-) zu
> überprüfen *g*
Dieses Device ist IMHO aber erst im neuen Kernel vorgesehen. Hast
Du da etwa schon einen Patch für den SuSE-Kernel? ;-)
[> Christian Boltz und Harald Krause in suse-linux]




More information about the AppArmor mailing list