ImportError in OSRNG/nt.py on Python 3 on Windows

Bug #1118255 reported by Jason R. Coombs
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Python-Crypto
Fix Committed
Undecided
Unassigned

Bug Description

In OSRNG/nt.py, the import looks like this:

import winrandom

On Python 3, this will result in an ImportError unless there is a top-level module called winrandom. I believe the intent is to import winrandom from the current package, i.e.

from . import winrandom

Furthermore, on Python 3.3, I was unable to get this actual error until I removed the circular imports around Crypto.Random and Crypto.Random.OSRNG.

Please let me know if I can supply more information to get this fixed. Thanks.

Revision history for this message
Darsey Litzenberger (dlitz) wrote :

Thanks for the bug report. The fix has been merged upstream: https://github.com/dlitz/pycrypto/commit/10abfc8633bac653eda4d346fc051b2f07554dcd

Changed in pycrypto:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.