74
top 50 comments
sorted by: hot top controversial new old
[-] namingthingsiseasy@programming.dev 55 points 2 months ago

My opinion: Python may not be the best at everything it does, but it's in the top 3-5 languages in the following areas:

  • Very easy to install, write and understand
  • Great libraries for a lot of applications
  • Large community, lots of people with experience in it

It will always be a practical choice for those reasons. There are probably a lot more as well that I can't think of at the moment.

[-] Henson@feddit.dk 32 points 2 months ago

I would add its a easy Scripting language. No compilation problem, richer that shell/bash makes it a powerfull choice.

And a really dont like it.

[-] furrowsofar@beehaw.org 9 points 2 months ago

It is far more then that. It is a full up programming language.

I never understand why people think compilation is a barrier. But sure most python is not compiled.

[-] eager_eagle@lemmy.world 4 points 2 months ago

If compilation takes more than a few single-digit seconds, IME, it breaks the development flow when you're working on small fixes.

[-] namingthingsiseasy@programming.dev 4 points 2 months ago

Having worked on large C++ projects, the solution to this issue is using a good IDE with an LSP. But it is quite a regrettable situation because setting up an LSP can be a difficult, and they also tend to break quite easily. Understanding how to make an LSP work is an important productivity skill in those kinds of positions.

load more comments (2 replies)
load more comments (6 replies)
load more comments (1 replies)
[-] driving_crooner@lemmy.eco.br 31 points 2 months ago

Python is not the best at anything, but is the second best at almost everything. That's the reason I use it. Everything I need to do, I know I can do it in python, maybe isn't going to be the better or faster it could be, but it will work.

[-] FizzyOrange@programming.dev 19 points 2 months ago

Very easy to install

This has to be a joke.

[-] Croquette@sh.itjust.works 6 points 2 months ago

Yeah, thought the same. Python isn't intuitive to install new packages.

[-] Valmond@lemmy.world 14 points 2 months ago* (last edited 2 months ago)

The libraries part is enormous. Researchers just pull up math engines, database access is a breeze, and so on.

You got a specific need, there is a library for it. It's like C/C++ without the hassle.

[-] masterspace@lemmy.ca 13 points 2 months ago

Python is popular because it's whitespace based syntax make noobs think it's easy to read. This and it's pre-installation on Linux made it popular amongst academics who embraced it for data analysis. This lead to a lot of data scientists embracing it and writing libraries for it which created a virtuous cycle in that arena.

And it's a damn shame because Python, and it's whitespace nonsense and lack of type system, is a horribly impractical language for building anything at scale.

[-] furrowsofar@beehaw.org 7 points 2 months ago* (last edited 2 months ago)

White space nonsense. Yes and no. I do not enjoy tracking down white space issues until I remember the alternative. Matching brackets, writing begin/end statements, and worst of all looking at code that appears well indented until later you find it is not. and it runs totally differently then it looks. Similar issues with semicolons.

Pretty much everyone uses LSEs these days so frankly matters less either way most of the time.

[-] Valmond@lemmy.world 6 points 2 months ago

It's not made for scale. Use C/C++ or something if you want scale.

[-] masterspace@lemmy.ca 11 points 2 months ago* (last edited 2 months ago)

Or you know, TypeScript, Go, C#, Java, Swift, etc. etc.

Python isn't great at anything except for having a lot of data science libraries already written for it.

[-] Valmond@lemmy.world 4 points 2 months ago* (last edited 2 months ago)

Not only data science libraries, there is a library for about anything. Which is not the case for your list of languages.

Edit: not all languages in the list.

When you understand how python works, it's quite simple to use too, and has lot less clutter than say java or c#.

[-] atzanteol@sh.itjust.works 7 points 2 months ago

Not only data science libraries, there is a library for about anything. Which is not the case for your list of languages.

Java has an excellent ecosystem for libraries. And a much more mature one in most cases than Python. The Spring framework alone is simply amazing.

Go's ecosystem is pretty good as well and getting better.

When you understand how python works, it’s quite simple to use too, and has lot less clutter than say java or c#.

The problem is that many python devs consider things like "type hints" and "classes" to be "clutter". It takes a lot of discipline to write managable python. Being "newb friendly" is a curse. "stringly typed" crap does NOT scale well.

load more comments (3 replies)
[-] eager_eagle@lemmy.world 5 points 2 months ago* (last edited 2 months ago)

It does make it easier to read. We primarily use indentation to match brackets, so clearly, indentation is the most important readability feature between the two, not brackets.

Try reading the same piece of code: without brackets, and then without whitespaces and tell me which is better.

Whitespaces as syntax force you to indent your code properly and not be misleading.

[-] masterspace@lemmy.ca 5 points 2 months ago* (last edited 2 months ago)

I literally do that professionally, and I'm telling you that brackets are inarguably better.

You are used to whitespace; I have literally spent months refactoring and upgrading a react frontend and a python backend and am telling you that brackets are a single character and far more predictable, and then your IDE / Linter / Formatter can reliably use them to fill in the perfect indentation and whitespace.

My first professional language was Python, but I have since tried a half dozen others and would never choose to go back to a whitespace based language unless there was a good reason.

load more comments (1 replies)
load more comments (1 replies)
[-] furrowsofar@beehaw.org 4 points 2 months ago

Typing thing is way over blown. What did suck before Python 3 was indeterminate type result from the / operator. You never know if it would be integer or floating division looking at the code. Now it is floating.

load more comments (3 replies)
[-] FizzyOrange@programming.dev 21 points 2 months ago

I think it's just because it is always recommended as an "easy" language that's good for beginners.

The only other thing it has going for it is that it has a REPL (and even that was shit until very recently), which I think is why it became popular for research.

It doesn't have anything else going for it really.

  • It's extraordinarily slow
  • The static type hints are pretty decent if you use Pyright but good luck convincing the average Python dev to do that.
  • The tooling is awful. uv is a lifesaver there but even with uv it's a bit of a mess.
  • The package system is a mess. Most people just want to import files using a relative path, but that's pretty much impossible without horrible hacks.
  • The official documentation is surprisingly awful.
  • Implicit variable declaration is a stupid footguns.

The actual syntax is not too bad really, but everything around it is.

load more comments (4 replies)
[-] brucethemoose@lemmy.world 21 points 2 months ago* (last edited 2 months ago)

It’s kind of crazy how problematic pip is, though. There are enormous ecosystems like conda, poetry, arguably Docker all built around “pip not working right.”

I see so many people want to install vllm or something with like a 95% crash and burn rate if they aren’t already proficient with Docker, complete with the spare disk space to basically ship a whole other machine.

Meanwhile, massively complex Rust or Go or whatever packages… just work. With the native tooling, for me.


To be clear, I like Python, and I believe many issues can be smoothed with time (like improving its JIT and maybe encouraging more typing in codebases). But pip and its ecosystem are forever cursed.

[-] rothaine@lemmy.zip 13 points 2 months ago

People used to shit on npm all the time, and I believed them, because I didn't have experience with anything else.

Then I tried pip. Holy...I had to beg npm forgiveness for ever doubting it

[-] tyler@programming.dev 9 points 2 months ago

npm was bad, for a very long time. Then they fixed it, because they actually listened to other languages and did what they did. Python still refuses to do that. It’s quite insane because Ruby has had a solution for 15+ years at this point and Python could have directly copied it but refuses to. Python is absolutely the worst language I know of in regards to tooling.

[-] brucethemoose@lemmy.world 7 points 2 months ago

Yeah.

I mean, npm deserves some healthy fear/skepticism, but everything is relative.

[-] FizzyOrange@programming.dev 8 points 2 months ago

pip is easily the worst thing about Python. But now that we have uv I would say the worst thing is the package/import system. I'm pretty sure only 1% of developers understand it, and it only really works properly if your Python code is a Python package.

If you treat Python as a scripting language and just scatter loose files around your project and run them directly, it doesn't work at all. Pain everywhere. Which is dumb as fuck because that's like 80% of how people use Python.

load more comments (1 replies)
[-] eager_eagle@lemmy.world 3 points 2 months ago

uv. Is like cargo for Python.

load more comments (1 replies)
[-] oddlyqueer@lemmy.ml 3 points 2 months ago

I'm glad it's not just me lol every so often I'll think "I haven't done a python project in a while I'll try FastAPI" or something and I have so many issues just getting the env set up.

load more comments (1 replies)
[-] jubilationtcornpone@sh.itjust.works 14 points 2 months ago

The blog gives a few vague answers, none of which shed any light on how Python became so popular. If I had to guess, much of it's popularity came from being embraced as a data analytics tool -- which is honestly a great use case for an interpreted scripting language -- and its subsequent adoption by academia, introducing it to an entire generation of CS grads.

Python has advantages and drawbacks like any programming language. It's not my favorite language and it's not my least favorite. It's not going anywhere anytime soon.

[-] LordCrom@lemmy.world 9 points 2 months ago

From an administrator POV, python is great for scripting, automation, and AWS boto work.

[-] Flamekebab@piefed.social 9 points 2 months ago

I would argue it's because it is Good Enough. The most popular solutions to things are rarely the optimum ones but the ones that are generally applicable.

For example, I could fight with bash's unpleasant syntax or I could do it more easily (but less efficiently) with Python. Would it be as performant? Absolutely not - but the performance gains wouldn't be worth the time and maintainability.

[-] furrowsofar@beehaw.org 7 points 2 months ago* (last edited 2 months ago)

Presumably because it minimizes developer time in writing code and is easy to use and it come with great libraries. That is why I have been using it since 1998.

Edit: People use to think I was crazy using Python. It was interesting seeing people slowly get a clue over the years.

[-] Feyd@programming.dev 5 points 2 months ago

It minimizes greenfield development time and increases it later for anything at scale. It's the mongodb of programming languages.

load more comments (11 replies)
[-] eager_eagle@lemmy.world 6 points 2 months ago* (last edited 2 months ago)

In the Python documentary they mention the early creation of numeric as an alternative for closed options like Matlab; which led to Python being used in the sciences and data processing. Then later it became the natural choice for machine learning in the early 2010s and the AI explosion of 2020+.

[-] ultimate_worrier@lemmy.dbzer0.com 6 points 2 months ago

Because most people are lazy hacks.

[-] xep@discuss.online 9 points 2 months ago

What is so lazy about Python?

[-] masterspace@lemmy.ca 4 points 2 months ago* (last edited 2 months ago)

Lazy is an overly harsh and judgemental way to put it (virtually all programmers start with some high level simplified language), but the sentiment arises because it's syntax is designed to be easy for people writing code, but at the cost of people maintaining code.

The whitespace delimiters, the lack of type system, the lack of semi-colons ... They're all things that people who haven't programmed before think make programming easier. In reality they all make in the wild production programs waaay harder to maintain.

There's a reason that JavaScript has been surpassed by TypeScript for professional developers, and it did so remarkably quickly. All that 'extra' information that seems pointless for a new dev to express, in reality constrains your program, makes it more readable and understandable, reduces the amount of tests you have to write, and makes it easier for someone else to come in and make a change to it and be confident they haven't broken anything.

[-] namingthingsiseasy@programming.dev 3 points 2 months ago

Python's type system is dramatically better than Javascript's though. Try doing things like '' + True and Javascript will do incredibly stupid things. Python will just give you a type error. Also, look at things like == vs === in Javascript as well. That's the biggest reason why Typescript replaced it overnight. Python has found a better balance between productivity and error safety.

In my opinion, the biggest shortcoming of Python's dynamic typing system is that you need to have very thorough test coverage to be sure that your code doesn't have semantic errors (a lot more than, say, Java). It has gotten better with the introduction of type hints, those I don't have much experience with them, so I can't say how much.

load more comments (3 replies)
[-] furrowsofar@beehaw.org 3 points 2 months ago

You can write Python code about 5x faster then C. Add libraries even faster.

[-] FizzyOrange@programming.dev 5 points 2 months ago

I mean... C is a low bar. You can write Typescript, Rust and Go code 5x faster than C too.

load more comments (2 replies)
load more comments (1 replies)
[-] Solemarc@lemmy.world 4 points 2 months ago

Nah, I recently had to create a program that turned a bunch of extracted CSV files into an XML file for government reporting. I also had to parse some provided government XML files to add things into my output.

This was going to be run by non-technical people on any OS so I went for python because "install python, download this file and click on it" was easy. Python has a big standard library so I could do everything I needed in it. I was considering using Go but asking people to open the terminal and build something was probably a bridge too far.

[-] syklemil@discuss.tchncs.de 11 points 2 months ago

Distribution usually isn't considered a strong point for Python, though.

For other languages that build a static executable, the more expected method of distribution would be some automated workflow that builds artifacts for various os/architecture-triplets, that you can then just download off the project page.

load more comments (2 replies)
load more comments (2 replies)
[-] humanspiral@lemmy.ca 4 points 2 months ago

Python is one of 4 key programming languages in world. C as a systems/performance/building block language (which I get has competitors). Javascript for node performance and web language. J as being the most powerful syntax/paradigm and best designed language.

Python has to be the most important due to all of the support it has, including C++ and other building block language/library imports that allows it to be the LLM integrator choice. A field that moves so fast, you couldn't import libraries fast enough in another environment. Another shoutout to J is that its terseness is a good LLM fit due to less token consumption. But integrating with python is essential.

[-] Reptorian@programming.dev 4 points 2 months ago

I'd say libraries is why it is popular. Also, I'm not a Python developer, and I don't bother with libraries.

load more comments
view more: next ›
this post was submitted on 02 Oct 2025
74 points (100.0% liked)

Programming

23761 readers
100 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS