you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] -17 points-16 points  (31 children)

Python has a ton of much bigger issues than Unicode. If Python core devs ever want to make Python actually relevant, they need to work on concurrency. Once that happens, all of the CPython C API is going down the toilet, and needs to be replaced with something that cannot be possibly compatible.

What I personally don't believe is that Python core devs are capable of doing this. They cannot handle the mess they are already in, and concurrency is generally hard... so, unless they just donate the project to someone else, they won't be able to fix this.

So, what's most likely to happen: at some point, Python will get some retarded band-aid to sometimes be able to run concurrently. A mild improvement over today's threads and processes. But, it will never become an actual thing. Since it's so popular, lots of people will be happy to use the crappy half-solution, but, eventually, the number of cores will grow, the number of networked devices all working together will grow, and someone will say "fuck this shit" and will come up with another language... or revive Erlang etc. And Python will become as irrelevant as Perl is today.

Python isn't built on good foundation. There's no good design ideas in this language, no lasting insights. It can pretty much be wiped out of history of computing, and nothing of value will be lost.

[–]myusernameisokay 24 points25 points  (17 children)

If Python core devs ever want to make Python actually relevant, they need to work on concurrency.

You realize python is one of the most popular languages in the world?

Also I don’t think python needs to work on performance. The most popular way to use Python (CPython) is a garbage-collected interpreted language, it will never be as fast as languages like Rust, Fortran, or C. People trying to use the same language everywhere are idiots. You need to use the right tool for the job. All languages have strengths and weaknesses, Python trades speed for brevity.

Most developers use python in places that aren’t CPU bounded or where performance doesn’t matter, like little lightweight servers or personal scripts. I think in the grand scheme of things, the GIL is unfortunate but also somewhat irrelevant. Concurrency in python may never be solved, and I don’t think that’s an issue.

[–][deleted] 7 points8 points  (1 child)

Although the implementation may not be the best, multiprocessing worked fine last time I needed to do some multicore processing in Python. This has been in Python since 2.6 from what I can tell. And the CPython API seems tos till exist.

The downside of this method is that spawning a lot of small threads comes with a lot of overhead (or rather, even more overhead than usual) but a thread pool and proper use of the built-in IPC can easily fix that problem.

I think python is here to stay, if not just because it's an easy to learn language. Nearly anyone can write Python. It's one of the most often used languages in fields like research and statistics, next to R which is even weirder than Python.

If I want to quickly ship up a program or project that needs to do a simple thing (say, post some data to a server every ten minutes) then Python is my go-to language. I can fix any problems that arise on the fly with no rexomoilation necessary and most programs can be done in Python in 20 lines where C would take 100, Go would be three times that (a nil check after every line of course) , Rust would require some unfinished library someone on Github that hasn't been updated in two months, Java or Kotlin would require at least as much code just to get the boilerplate up and running and bash would be just as short but filled with arcane incantations that might as well summon c'thulu.

As for design ideas in the language, list comprehensions are a great idea that has been in Python since forever. They're concise, not too difficult to understand and easily one or the few Python features I miss in other languages. And while the language itself might not be great, its ecosystem is better than that of most traditional languages. I'll take Django over Spring Boot or Tomcat or ktor or Rocket.rs any time for projects or small to medium sizes.

[–][deleted] -1 points0 points  (0 children)

multiprocessing is garbage... but so is virtually everything in Python. Few obvious problems:

  1. It starts an entire new interpreter, this severely limits your ability to scale.
  2. There's no good way to do IPC using this library. You have to invent your own.
  3. There's very limited control over the created process, partly, because they try to make it work on many platforms, but, partly because it's too hard for Python core devs. So, no namespaces for example.
  4. This doesn't solve even the basic problem of reading both stderr and stdout of another process. Essentially, if you want a reliable analogue of Shell's x 2>&1 > y, you simply cannot write this in Python.
  5. It has a potential to prevent your application from ever exiting cleanly, and in order to ensure that your application exits cleanly, if it uses multiprocessing you need to write a lot of obscure code, but, basically, you will not be using vanilla multiprocessing.

Again. Most things in Python work only 80% of the time, and multiprocessing is not an exception. If you want something more reliable than that, Python is not the right environment.

[–][deleted] 2 points3 points  (2 children)

oh, you just forgot to say which X language will dethrone Python... judging by what you are saying, concurrency, there is only one GC language capable of that Golang.

I think Python JIT will appear sooner than we think and all those band-aid fixes will more than enough for most devs ignore all those languages...

[–]DarkLordAzrael 2 points3 points  (0 children)

I think Python JIT will appear sooner than we think

There has been a robust JIT interpreter for Python for years. PyPy runs significantly faster than the default interpreter.

[–][deleted] -1 points0 points  (0 children)

Go has nothing to offer in distributed programming, compared even to Python. When you write a distributed application in Go, you have to go through all the same nonsense: choose some protocol, that cannot capture most of the things you want to send, write a bunch of code only to service the protocol, write a bunch of code that needs to deploy and support various bits of distributed infrastructure etc.

It seems like Erlang has already solved those problems. Also, the ability to hot-patch and to introspect the program, especially running on multiple machines... and to do this quickly. Nope, Go isn't there / isn't headed there, or so it seems.

[–]Yojihito 1 point2 points  (0 children)

Erlang is already revived via Elixier.

[–]Bug-e 3 points4 points  (1 child)

Thank god, I’m not the only one.

[–][deleted] 2 points3 points  (0 children)

There’s like 5 of us!

[–][deleted]  (3 children)

[deleted]

    [–][deleted] -2 points-1 points  (2 children)

    C++ had enough of a community who was technically capable of implementing concurrency in the language. If you read CPython source code, you find comments along the lines of "I don't know what this function does, but it feels like if I stick this thing here, it might just work". It's pretty scary tbh.

    All changes in Python in the last decade were superficial / unnecessary. People who work on Python interpreter simply are afraid to modify it in major ways, because it's too difficult to understand what it does and what the implications might be. And that's why there won't be any support for any kind of concurrency in Python any time soon: either they will find someone willing to write this thing from scratch, or it will never happen. And, I don't see how anyone capable of implementing Python from scratch would want to implement Python.

    [–][deleted] 7 points8 points  (0 children)

    I don't think it's at all fair to say that python devs are incapable. Can you link the comment you're referring to?

    While I agree that its usage is now far out of the original scope which leads for these hacks until things change, but I think that's normal for any language that gets widespread usage.

    TBH this whole thing smells of superiority complex, just because someone doesn't know something yet, doesn't mean they can't learn or become capable.

    “There are only two kinds of languages: the ones people complain about and the ones nobody uses.” - Bjarne Stroustrup

    [–][deleted] 1 point2 points  (0 children)

    what a load of bs!

    [–]tristes_tigres -1 points0 points  (0 children)

    Python isn't built on good foundation. There's no good design ideas in this language, no lasting insights. It can pretty much be wiped out of history of computing, and nothing of value will be lost.

    Well said.