Why I'm Making Python 2.8
161–170 of 392 posts
Re: Why I'm Making Python 2.8
#162Earlier quoted context omitted.
Yes, the built in csv module really does that in Python 3. If you pass it bytes, yes, it does. If you pass it strings, no, it doesn't. If what you pass to the built-in CSV writer is not a string, the CSV writer will call str() to get a string representation it can write out. The string representation of a bytes object includes the 'b' prefix. Meanwhile, you discovered your bug: you were treating bytes as text, which…
I had this problem. It doesn't "blow up". If it blew up and retired, I would have seen the problem. The problem, like several python 2/3 incompatibilities, is that Python 3 merrily did something different, without telling anyone, until eventually we track down what has changed. I spent quite a while on this very bug myself, and it, along with others, persuaded me to switch to a different language (serious I know, but…
It's not a bug, it's a fix for an architectural error in Python 2, and it was quite well announced at the time: https://docs.python.org/3.0/whatsnew/3.0.html
Re: Why I'm Making Python 2.8
#163Earlier quoted context omitted.
> Only for the specific case of input bytes already in the language's internal encoding (which granted will be common as most inputs would be ascii or utf-8) and with the same ownership constraints as the input, and that's mostly enabled by Rust's ownership model. Except of course on operating systems where text I/O is done entirely in UTF-16. Say, Windows. Since Python strings have no fixed encoding, but choose "the…
> Since Python strings have no fixed encoding, but choose "the most efficient one" (heuristically) when decoding, they can cope better than a fixed UTF-8 encoding in these cases. That is wrong. Python can never pick the most efficient encoding unless you decode from latin1.
Re: Why I'm Making Python 2.8
#164> And the majority of Python code written does not run under any of the 3.x interpreters. This makes it harder for its users to be productive. What a load of bollocks. For new projects this only matters if libraries aren't ported, which they are for the most part. For old projects, either you're in a situation where you can spend time porting your code to Python 3, or you don't; but as TFA mentioned pep-404, the writ…
> What a load of bollocks. For new projects this only matters if libraries aren't ported, which they are for the most part. For old projects, either you're in a situation where you can spend time porting your code to Python 3, or you don't; but as TFA mentioned pep-404, the writing has been officially on the wall ever since 2011 so at that point you have to admit you did choose to incur tech debt and do nothing about…
Re: Why I'm Making Python 2.8
#165> And the majority of Python code written does not run under any of the 3.x interpreters. This makes it harder for its users to be productive. What a load of bollocks. For new projects this only matters if libraries aren't ported, which they are for the most part. For old projects, either you're in a situation where you can spend time porting your code to Python 3, or you don't; but as TFA mentioned pep-404, the writ…
Except when they aren't. And then what?
I've run into this multiple times. Sometimes there's a branch of the project for 3 that's underway, and I sit and wait. Other times it means dropping the project or committing to reimplementing a library.
Re: Why I'm Making Python 2.8
#166Earlier quoted context omitted.
Python is trademarked by the Python Software foundation. IANAL but pretty sure that means he doesn't get to call it Python 2.8
Only if the PSF does something about it...
They could license it to Python 2.8 for free if they want to, though it seems unlikely.
Re: Why I'm Making Python 2.8
#167I think the problem for me is that they did these changes and made a big song and dance about Python 3. If they had have called Python 3.0 v2.9 instead everyone would have been clear they had to migrate. PHP has been successfully deprecating features for decades now and cleaned up their code base; they have never had a schism in the way Python has so you can argue all you want about legacy, or people preferring 2.7.…
The PHP Project did manage to allow people to write code that worked on both 4 and 5. At the same time, the project failed to get Unicode in. It's unclear how that will be possible without breaking a lot of programs. If PHP ever switches string handling like Python3 did now, it will be just as painful. Well, that's my prediction anyway, maybe they will figure something out. Just realize that their first try (PHP6) didn't fly at all.
Re: Why I'm Making Python 2.8
#168I never knew that despite Python 3 is called the future by PSF and has been around for a ling time, people still want to stick to Python 2. I mean it isn't the 2013 that libs aren't ported, most famous ones generally are ported. Don't know what the problem is.
Re: Why I'm Making Python 2.8
#169Earlier quoted context omitted.
Are you implying Python3 is repressive?
"Port your old code or be left behind when we cut off 2.x line" is.
Re: Why I'm Making Python 2.8
#170I think the problem for me is that they did these changes and made a big song and dance about Python 3. If they had have called Python 3.0 v2.9 instead everyone would have been clear they had to migrate. PHP has been successfully deprecating features for decades now and cleaned up their code base; they have never had a schism in the way Python has so you can argue all you want about legacy, or people preferring 2.7.…
>If they had have called Python 3.0 v2.9 instead everyone would have been clear they had to migrate. Massive breakage of backwards compatibility in a minor release is bad form. They absolutely did the right thing by naming it Python 3.0.
Rather than have this huge break maybe just take the time to move all of Python forward rather than us still 8 years after Python 3 leave us still talking about it.