Main changes:
================================================
- Print function - PEP 3105[1]
- Design of dictionaries, their iteration and respective built-in
functions - PEP 469[2], PEP 3106[3]
- Division operator - PEP 238[4]
- Interrupts of system calls - PEP 475[5]
- Socket.accept and interrupts - Docs Python3 Socket[6]
- Universal newlines - PEP 278[7], PEP 3116[8], Docs Python3
Subprocess[9]
- Binary data and strings - Docs Python3 porting[10]
- Shebangs modified to environmental variable of python3
- Fixed library imports to reflect their respective changes in
transition to python3
- multiprocessing
- xmlrpc
- urllib
- thread
- pickle
InterfaceManager.py
================================================
- Byte string and unicode/ascii string conflict, fixed by mostly
using a byte string through the project
NetTestSlave.py
================================================
- signum 2 (SIGINT) - modified behavior since python 3.5
- Due to changes in interrupting system call, signal receiving and
handling required changes to main slave loop
- Structure of raising, catching and handling interrupt was changed,
to reflect behavior of python 3.5 and higher
- Method run is no longer ended by parameter "finished", but rather
exception breaks the endless loop
SecureSocket.py
================================================
- Byte string and unicode/ascii string conflict, fixed by using bytes
internally and sending messages encoded to ascii
- Fixed multiple issues regarding changes to standard python functions,
such as encoding to hex, ordinal value of characters, length of
different types
NetTestCommand.py
================================================
- name_start_char is using unicode string, therefore each unicode has
to be escaped twice
ExecCmd.py
================================================
- Popen universal newlines
- Abstraction to be able to read newlines regardless of system used
and its basic encoding
XmlParser.py
================================================
- etree.tostring function behavior changed to generate byte string
by default
- Unicode encoding is required, as specified by parameter
NmConfigDevice.py
================================================
- Conversion of bytes array to integer value was changed, ord no longer
returns plain integer value
- Need to convert bytes array to integer - int.from_bytes
- Reverse conversion does not need to account for bytes array,
therefore it is redundant to convert IP twice
ShellProcess.py
================================================
- Decoding file stream, to use unicode string instead of byte string,
as built-in function read returns byte string by default in python3
Netperf.py
================================================
- Changed evaluation of results to account for changes made to base
types in python3
- Dictionary comparision with integer by their respective lengths
and values
Machine.py
================================================
- List comprehension functionality in python3 was changed
- New function to parse queried addresses from slaves - modified
code from next branch
- get_ip_addr returns a dictionary or IP address objects - fixed to
return only IP address portion by getting addr attribute from
dictionary
================================================
[1] - PEP 3105
https://www.python.org/dev/peps/pep-3105/
[2] - PEP 469
https://www.python.org/dev/peps/pep-0469/
[3] - PEP 3106
https://www.python.org/dev/peps/pep-3106/
[4] - PEP 238
https://legacy.python.org/dev/peps/pep-0238/
[5] - PEP 475
https://www.python.org/dev/peps/pep-0475/
[6] - Docs Python3 Socket
https://docs.python.org/3/library/socket.html#socket.socket.accept
[7] - PEP 278
https://www.python.org/dev/peps/pep-0278/
[8] - PEP 3116
https://www.python.org/dev/peps/pep-3116/
[9] - Docs Python3 Subprocess
https://docs.python.org/3/library/subprocess.html
[10] - Docs Python3 Porting
https://docs.python.org/3/howto/pyporting.html#text-versus-binary-data
You forgot to add the "Signed-off-by:" line for the v2 patch...
If you agree I can add it manually and push the changes to the
"master-py3" upstream branch.
-Ondrej