Open rshmhrj opened 3 years ago
Python v3.2 introduced tobytes() and kept the deprecated tostring() as an alias for tobytes()
tobytes()
tostring()
This fix checks the current sys.version_info and chooses arr.tobytes() if the version is at least 3.2,\ otherwise it uses arr.tostring()
sys.version_info
arr.tobytes()
arr.tostring()
Python v3.2 introduced
tobytes()
and kept the deprecatedtostring()
as an alias fortobytes()
This fix checks the current
sys.version_info
and choosesarr.tobytes()
if the version is at least 3.2,\ otherwise it usesarr.tostring()