Live data from Hacker News

Breaking up with Python

cedwards.xyz

21–30 of 179 posts

Re: Breaking up with Python

#21
I tried python in 2010 because looks easy, but Go came on stage, and changed backed tools.

Go is the way to better backend, CPU and memory optimized.

I read an article that Dropbox save thousands just by change from Python to Go.

It's difficult, especially handling shared variables in go routines, but it's worth it.

Re: Breaking up with Python

#22
post #9
post #4

I have just started getting into python as I'm experimenting with pytorch and after a lot of googling I'm still trying to figure out how to use conda properly. Could anyone point me to the best way to manage python environments and packages?

Tried tons of ways, and finally found peace of mind with poetry: https://python-poetry.org/ It encourages to set up project specific definitions which are saved in the local pyproject.toml file. Keeping everything local and project specific, including the env definition, turns out to be a fantastic boon to reproducibility and sanity of mind.

Thanks! this is exactly what I was looking for.

Re: Breaking up with Python

#23
post #11

I don't fully agree with these arguments, but they all have some validity. I really felt his point on the documentation - it's great that it's reference-complete if that's what you're looking for, but it's maddening if you are coming to something to find out what it does.

I often find myself typing python3 import some_module dir(some_module) rather than trying to find functionality on the docs sites anymore

Lately i've been using ChatGPT for that instead and it's phenomenal. Previously, I'd just open up my site-packages folder in a dedicated Sublime window and just search the source code for what I wanted to know.

Re: Breaking up with Python

#25
post #14

The article mentions using JavaScript in place of Python. I use JavaScript a lot for browser stuff but can JavaScript be used for the random command-line scripts that I implement in Python? (Genuine question, not rhetorical.)

Yep.

Re: Breaking up with Python

#26
post #4

I have just started getting into python as I'm experimenting with pytorch and after a lot of googling I'm still trying to figure out how to use conda properly. Could anyone point me to the best way to manage python environments and packages?

Pyenv for Python versions and/or environments, Poetry for package management and/or environments, and pip if you end up needing it for package management.

Re: Breaking up with Python

#27
I have gripes with some things in the current state of Python, package management particularly, but choosing JavaScript because Python's standard library is "barebones" doesn't really make any sense to me.

I've always found the Python standard library to have tons of useful stuff, and when I'm doing something in JS I often feel like I'm missing my toolbelt or something. Then I install a single npm package to do something simple and it winds up having 350 dependencies.

Re: Breaking up with Python

#28
Meanwhile, it was the most used language to solve the advent of code, and the language the winning solutions tended to be written in.

> my go-to language for a quick bit of scripting where another language might feel too heavy duty

So this article is not from someone who has used Python full time professionally...

Re: Breaking up with Python

#29

I've been recommending Python to the occasional aspirational young programmer. Is it already passé? What would you recommend instead for a starter language? Looking for beginner-friendliness, widespread use, and longevity. edit: to be clear, I hope this won't devolve into a language flamewar. I'm sincerely interested in other devs' opinions, and hoping that either Python is still a good recommendation (which seems to…

I have, for the life of me, never understood the 'beginner friendly' argument for python.

Java, PHP or JavaScript for 'widespread use and longevity'. None of these are going anywhere, and I think you'd find more resources for beginners to advanced users for those 3. Yes, of course there's others - everyone has their faves. And Python will continue to kick around as well, but I've just never understood the 'beginner friendly' bit.

Re: Breaking up with Python

#30
The thing is, every language has serious issues, whether usability issues, documentation issues, performance issues, community issues, standard library issues, dependency issues, whatever. And for every issue, there are some people who just don't feel affected by it (or disagree that it is even an issue), and others who feel it deeply, to the point of outrage. So even if you ever get a consensus on what the issues are, there's even less of a consensus on how much they matter and what to do with them. Some people can live with certain problems and others are really distracted or bothered by them. It depends hugely on the context and environmental constraints too (can your org switch languages? when? on what terms? etc).

I think there's something deeply path dependent about how software people go through languages and fall in and out of love with them. Python was the first language I ever used professionally. It was amazing at the time compared to Java. But I haven't touched it in years now and don't especially want to. It's not that I "broke up" with it -- I just went elsewhere and it wasn't used there. You usually have to speak the local language wherever you go...

At a certain point, I think a lot of us give up on the idea of "loving" or "not loving" the language we use. They are all just tools. Some professional software people still have love affairs with their tools. That's cool I guess, but I have to say, I've written useful software in horrible languages (PHP) and I feel good about that too, and about not caring about the lovability factor (so to speak) of my professional toolkit.

Post reply on HN