summaryrefslogtreecommitdiff
path: root/python-3-changes.txt
diff options
context:
space:
mode:
authorThorsten Behrens <sbehrens@gmx.li>2010-12-29 05:29:08 -0500
committerThorsten Behrens <sbehrens@gmx.li>2010-12-29 05:29:08 -0500
commitca701f92f538ddd61835a2ec252ebbb8a0b1e4de (patch)
tree7f328bedc0a41e5430bcb70bc535e6069d99e276 /python-3-changes.txt
parentbaa9119a1448368d618fb2977b47a5c59a389533 (diff)
downloadpycrypto-ca701f92f538ddd61835a2ec252ebbb8a0b1e4de.tar.gz
PY3K support for _fastmath.c; removed floordiv(a,b) hack and replaced with divmod(a,b)[0]; move to assertEqual throughout the test suite to prep for assert_ and failIf being removed in 3.3/3.4
Diffstat (limited to 'python-3-changes.txt')
-rwxr-xr-xpython-3-changes.txt6
1 files changed, 4 insertions, 2 deletions
diff --git a/python-3-changes.txt b/python-3-changes.txt
index d1abc66..51f9455 100755
--- a/python-3-changes.txt
+++ b/python-3-changes.txt
@@ -31,8 +31,10 @@ Replace string.split(a) with a.split().
Replace body of white-space-stripping functions with 'return "".join(s.split())'
Integer division via the "/" operator can return a float in 3.x. This causes issues in Util.number.getStrongPrime. As 2.1 does not support
-the "//" operator, a helper function "floordiv()" is brought in via 'if sys.version_info' from floordiv.py or py21floordiv.py.
+the "//" operator, divmod(a,b)[0] is used instead, to conform with an existing practice throughout the rest of the pycrypto code base.
+Do not use assert_/failUnless or failIf. These are deprecated and are scheduled to be removed in Python 3.3 and 3.4.
+Use instead assertEqual(expr,True) for assert_ and assertEqual(expr,False) for failIf
C code:
@@ -68,6 +70,6 @@ TODO:
This is friendlier than just relying on Python's errors.
- Document the expected types for functions. The cipher, the key and the input texts are byte-strings. Plaintext decodes are byte-strings currently, this needs review.
In keeping with how Python 3.x's hash functions work, the input MODE is a text string. hexdigest() returns a text string, and digest() returns a byte-string.
-- Compile and test _fastmath.c
+- Look into LIBPATH/%LIB% and /NODEFAULTLIB:LIBCMT in setup.py for libgmp/libmpir
- Go through test cases and see which modules are not covered
- Look into exclusions in setup.py