forked from paramiko/paramiko
-
Notifications
You must be signed in to change notification settings - Fork 4
Information on pre2to3 branch
goertzenator edited this page Feb 8, 2011
·
4 revisions
The purpose of the pre2to3 branch is to clean up Paramiko for Python 2 so that the 2to3 tool runs with fewer errors and silly changes.
The changes applied are:
- Most
range()
changed toxrange()
.xrange()
was already being used in some places. - Some
keys()
changed toiterkeys()
. - Some
values()
changed toitervalues()
. - Some type checking of the form
type(x) is long
changed toisinstance(x, long)
The above changes are compatible back to 2.2, so there should be no issues with merging these to Paramiko master. These changes should also increase performance since many large lists are now iterators.
More Changes:
- Change
UserDict.DictMixin
tocollections.MutableMapping
. Breaks compatibility with <2.4 - Removed has_key() tests for HostKeys class because has_key() is deprecated, and is not implemented by the underlying MutableMapping class.