by pcmonk · 11y ago · 0 comments
Until you need to use some library that doesn't support python3. I think I've made the transition from python3 to python2 more than I have the other way around.
More and more of the bigger libraries are ported already, and a lot of the others have been replaced by newer libraries that work with Python 3. If the library you're trying to use doesn't support Python 3, it's probably a good indication most people have moved on to something better...
>>> b"%u" % 5
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: unsupported operand type(s) for %: 'bytes' and 'int'json.loads(foo) blahblahException foo is bytes not text.
That said I still endorse py3 for new things
If I remember right, % used to be deprecated in Python 3, but was undeprecated again by popular demand.