Live data from Hacker News

The Case Against Python 3

learnpythonthehardway.org

201–210 of 281 posts

Re: The Case Against Python 3

#201
post #67

> The strings in Python 3 are very difficult to use for beginners. In an attempt to make their strings more "international" they turned them into difficult to use types with poor error messages. Every time you attempt to deal with characters in your programs you'll have to understand the difference between byte sequences and Unicode strings. The author has this exactly backwards. It is Python2 that makes the weird di…

> Python bytes are constrained to be 8-bits wide

??

Aren't all bytes 8 bits wide?

Re: The Case Against Python 3

#203
post #201
post #67

> The strings in Python 3 are very difficult to use for beginners. In an attempt to make their strings more "international" they turned them into difficult to use types with poor error messages. Every time you attempt to deal with characters in your programs you'll have to understand the difference between byte sequences and Unicode strings. The author has this exactly backwards. It is Python2 that makes the weird di…

> Python bytes are constrained to be 8-bits wide ?? Aren't all bytes 8 bits wide?

Nope! (TIL) http://stackoverflow.com/questions/5516044/system-where-1-by...

I think in the context of the original answer there's also the problem that char types aren't necessarily 8 bits wide, e.g. wchar etc.

Re: The Case Against Python 3

#204

This has to be the ne plus ultra of Python scaremongering. It describes some sort of bizzaro world of a doomed language which it populates with Machiavellian Python maintainers, brainwashed developers, and a small group of heroic holdouts who see resisting Python 3 as a moral imperative. Apparently having too many string formatting options is a moral issue (three, to be specific). As someone who writes a _lot_ of Pyt…

Think Python is pretty approachable for newcomers. It's also made available for free, and fwiw has a version for 2 and 3.

http://greenteapress.com/wp/think-python-2e/

Re: The Case Against Python 3

#205
post #201

Earlier quoted context omitted.

> Python bytes are constrained to be 8-bits wide ?? Aren't all bytes 8 bits wide?

Nope! (TIL) http://stackoverflow.com/questions/5516044/system-where-1-by... I think in the context of the original answer there's also the problem that char types aren't necessarily 8 bits wide, e.g. wchar etc.

Ok, I should have been a bit more specific: aren't all bytes on machines that Python can realistically run on 8 bits wide?

Re: The Case Against Python 3

#206

Earlier quoted context omitted.

As a writer of "quick n' dirty" webapps for internal use, I use python3 because philosophically, I want to help the world move forward, and the standard library has more stuff in it.

Ditto. I have submitted at least 10 PRs to fix Python3 bugs in OSS projects directly because of this. So perhaps I have made the world .000001% better.

Thank you!

Re: The Case Against Python 3

#207
post #78
post #5

On the other hand, I never suggest Learn Python The Hard Way or Codecademy to any new programmer, because I don't want them to ask me down the line "why you directed me to an obsolete Python course?". I think I'm not the only one. So I'm not sure what's the net result of those decisions made by the two sites, do they really help in keeping Python 2 alive?

I attended a few newbie classes at pycon2016. A few of them suggested Learn Python The Hard Way, to which I pointed out how the author states to never try installing python 3 on the first page.

I also saw that but gave the author benefit of doubt that may be the book was written years ago and not updated. I have completed switched to python3 for almost 2 years now.

Re: The Case Against Python 3

#209

This has to be the ne plus ultra of Python scaremongering. It describes some sort of bizzaro world of a doomed language which it populates with Machiavellian Python maintainers, brainwashed developers, and a small group of heroic holdouts who see resisting Python 3 as a moral imperative. Apparently having too many string formatting options is a moral issue (three, to be specific). As someone who writes a _lot_ of Pyt…

I feel like I'm the only one who learned Python from the official site's tutorial page: https://docs.python.org/3/tutorial/index.html I found it really helpful.

Did you learn programming from that tutorial or just python? What's good about Learn Python the Hard Way is that it first and foremost teaches programming, with python largely being an implementation detail.

Re: The Case Against Python 3

#210

Earlier quoted context omitted.

Python is an interpreted language, so the comparison is meaningless. It is cheap to deal with the ambiguity in the compiler using compile options. You could go the Java way and have separate class path (e.g. In PyPy, as CPython 2.x is dead). But this does not allow you to mix and match code for older version anyway. Java was designed from start to allow this and it is why it's so stagnant.

Python is an interpreted language, so the comparison is meaningless. Bash has no problem running old Bourne shell scripts from ancient history. Browsers have no problem running JavaScript from the mid-90s. I fail to see how being an interpreted language is a valid reason for breaking backwards compatibility.

being interpreted is not a valid reason, but the string class for both bytes and text is a valid reason.
Post reply on HN