3 ms·
The reason it might be hard to port python 2 code to python 3 is because most likely it is buggy. Python 3 is much stricter about distinguishing bytes from str
by takeda 11y ago
The reason it might be hard to port python 2 code to python 3 is because most likely it is buggy. Python 3 is much stricter about distinguishing bytes from strings.
Making python 3 code compatible with python 2 (2.7 and 2.6) is much easier, granted you don't use new features exclusive to 3.x.
That's what I did so far with multiple applications and have yet to find case where I couldn't make my code work on 2.x and 3.x with adding import _future_ and in some cases six module.