Live data from Hacker News

“Python's batteries are leaking”

pyfound.blogspot.com

401–410 of 420 posts

Re: “Python's batteries are leaking”

#401

Earlier quoted context omitted.

> Still don't know how to do it "correctly" when writing Python 2-compatible code. Does writing python 2 code stop being 'worth it' at some point? If so, where is that point? It sort of sounds like you're already there. There's still people using P2 at least in part because of all the hoops people are jumping through to keep supporting it, no? I'm not a professional python dev, so it doesn't impact me as much as some…

> Does writing python 2 code stop being 'worth it' at some point? If so, where is that point? It sort of sounds like you're already there. How do you know I'm there? If nothing else I still have my own previous Python 2 code that I've spent time on and that's useful to me! Why would I just throw them all away or waste massive amounts of time rewriting them into Python 3? Is my goal supposed to be to please the masses…

> just because someone made something shiny and declared it "unsupported"?

Part of the argument for using much of the stuff out there is because it's "supported" (commercial, community, etc). Without some degree of support, things dwindle/die. The 'support' for language stuff may simply be security patches. If/when those stop being provided, you're starting to do a disservice to people to continue to push that language, even if the core functionality you need is still working and perhaps even unaffected.

> I'm not targeting Python 2 ... I try hard to keep my code both Python 3 and Python 2 compatible.

Given that there are breaking changes between the two, I can't read this any other way that that you're 'targeting' Python 2. If there's a way to do something in 2, and it's not working that way any more in 3, and you're making code so that it runs in both (weird syntax, translation layers, etc) then... you're targeting 3. The same way that if you use 3 syntax, you're 'targeting' 3. That's just how it is.

> but people use it because it benefits them, not "because it's supported".

The benefit is that they don't have to go through whatever hoops it takes to upgrade to have the latest versions. In many cases the later version may not add much directly, but 'community support' and 'security' are two ... emergent properties of a critical mass adopting new versions and dropping support for old versions.

> How do you know I'm there?

Wild-ass guess from the gist of all your earlier posts in this thread?

> But if you want a more "standard"/politically-correct response: Python 2 is still being supported,

I'd say that's partially 'under duress'. My reading of the situation years ago was that the Python community - at least the leadership - wanted to EOL P2 on Jan 1, 2015. There was a gigantic stink/pushback, and support was extended for another 5 years. I will grant that the v3 switchover was pretty bad - I'm not a pro user, but had some colleagues that dealt with a lot, and certainly, 8+ years ago, it was pretty hard to just 'switch' running systems. Even developing new stuff from scratch - there were a lot of 'only works in 2' libraries that were entrenched standards without clear update paths. However, rather than doubling down and making 3 a more attractive proposition (work on upgrade path, faster language, better docs, whatever), the agreement was to support P2 for another 5 years. That's an eternity in the tech world. You could argue it shouldn't be, but it is. Yet, from python colleagues - those who've stayed - the upgrade story isn't significantly better. I'm taking their word for it, but based on your posts, it doesn't seem to be either.

Re: “Python's batteries are leaking”

#402

Earlier quoted context omitted.

If Tkinter goes, then Python is dead to me. I use Python for small dep-free single file GUIs for small projects meant to be used by people who have Python installed but can't be bothered to go through an installation checklist. Tkinter is great for that and is the only reason I bother using Python for anything.

"pip install --user -r requirements.txt" is not a terribly odious "installation checklist", and I don't think it's the start of a slippery slope towards one either. If you're worried about people not RTFM when using your projects, you could always start your scripts with the standard try/import/except wrapper around the required package, and tell them to run pip install when it's not found--or (and this is a terrible…

Asking my users to use the command line is odious.

Re: “Python's batteries are leaking”

#403

Earlier quoted context omitted.

Those libs did not come out of nowhere, and the language did not rise from 1991 to the today without inherent qualities that draw people to it. Python didn't have any specialty like PHP, or an accidental monopoly like JS. It didn't come with a killer app like Ruby. It hasn't been made by a giant company like Go. It's pretty much a self-made language.

I'm not sure if I'd agree. Python was pretty lucky to have numpy/pandas when "data science" started taking off a few years ago. It easily could have been another language.

Pretty lucky to be an overnight success, 25 years in the making.

Re: “Python's batteries are leaking”

#404
post #390
post #376

Earlier quoted context omitted.

There’s other languages that fit the same criteria that are much better: Scala, OCaml, Racket, or Haskell. The inherent qualities that draw people to Python are that it’s so inexpressive and crippled that you can learn it in 30 minutes.

Agreed. Most people who like Python seem to never have had experience with functional languages.

Most people don’t have much experience. Any more middlebrow dismissal to offer?

Re: “Python's batteries are leaking”

#405
post #114

I have mixed feelings about this because I've seen both parts of the same situation. In certain situations, I've been working with a python interpreter on a RHEL machine where pip was not installed (and I was not allowed to install it as well as make other modification: the machine was owned by the client and I had to work with what I had available). - having some basic functionality in the core libraries was a godse…

[deleted]

Re: “Python's batteries are leaking”

#406
post #2

Why, time and time again, does Guido seem incapable of reasonable debate, or ideas that challenge his own? It's completely rude to interrupt a presenter with 'what is your point?' Years ago I was in contact with the author of Nuitka, who was very excited to share his work thus far. During his presentation, Guido kept huffing and making snide comments under his breath. All because he disagrees with the premise behind…

What’s your point? Because it is easy to criticize an important work. Not so easy to help improve it or leave it be due to historical and compatibility concerns.

Re: “Python's batteries are leaking”

#407
post #262
post #192

Earlier quoted context omitted.

Python was one of the first languages I learned. Recently started using Go a little, and it does feel better but it just takes longer for me to write (probably because it's newer to me too). At work, people want things quickly. I'd love to be able to spend my time writing things properly in Go, but it's just not as quick and easy as Python is.

This is entirely anecdotal, but my experience has been that many people espouse the speed of Python development when in fact they put out sloppy, non-production ready code that needs a ton of extra review, effort, and sprints to get up to snuff. I often find myself producing higher quality, production ready Python code than those who cling to it like a safety blanket and complain non-stop about how "slow" languages l…

Sounds like you are blaming Python because it is easy to use, therefore enables poor programmers to work.

I’d rather have the first and risk the latter than the alternative.

Re: “Python's batteries are leaking”

#408

Earlier quoted context omitted.

If a programmer is lazy, forcing him to use Java or C++ isn't going to fix it. And I've seen good developers ship plenty of quality code in Python or Ruby.

That's not what I'm saying, what I'm saying is that if there is a known bug in a python library, don't use it and code it from scratch. Especially if your job is to roll it out at a large scale. You could save your company tons of money just by taking the time to do it right. But yeah, you can ship python and ruby all you want. That's fine, but if you are using buggy or broken libraries because you don't want to code…

This is a strange grab bag of ideas. You take Python’s strengths at prototyping and wide support and make them sound like weaknesses. Right tool for the job has been a saying for a while.

Re: “Python's batteries are leaking”

#410
post #370

I had to code in Python recently and had PTSD over all the syntactically significant whitespace. I have no idea how I ever found productivity in the language coming back to it now with fresher eyes. Refactoring, editing, and writing new code feels like such a drag.

I don't think Python is worth using for most new non-data science projects nowadays. The language is ugly and hard to work with. Also the performance is terrible.

There’s no accounting for poor taste.
Post reply on HN