Hacker News new | ask | show | jobs
by codonaut 4781 days ago
Can anyone explain why exactly a script written in one language would stall, while the same script in another wouldn't? Is there that much inherent instability in Python? Can it be assumed that the scripts in this case aren't comparable?
3 comments

Without actually be able to see either script, I would assume that his Go implementation took advantage of some of Go's more natural concurrency features.

The only reason I'd assume the Go version was concurrent and the Python one wasn't is that concurrent processing in Python can be very prickly. That is by design. Guido has talked about how adding too much support for concurrency at the language level would complicate things and probably end up with a language that was very non-Pythonic.

A completely different implementation would seem likely to have been made.
> Can anyone explain why exactly a script written in one language would stall, while the same script in another wouldn't?

It stalls in Python because the author is not acquainted with non-blocking system programming (the select()-call, which has been around since at least the eighties and has been a part of core Python since a very long time).

As to why a software developer who did not invest some minimal time into learning basic system programming feels qualified to write a blog post about this topic is another question.

It's funny how people who learn evented programming in scripting languages like Python feel like they've discovered some new hidden concept. No competent systems developer fails to understand what select() does. Suggesting that the author was't "acquainted" with select says more about this comment than about the author of the post it comments on.
>It stalls in Python because the author is not acquainted with non-blocking system programming

Citation needed.

How about "he is acquainted but can't be bothered to use it retrofitted to a language not tailor made for it"?

>As to why a software developer who did not invest some minimal time into learning basic system programming feels qualified to write a blog post about this topic is another question.

And why you think you're any better than him based on a short blog post (and especially one in which he does not delve into why the Python version was slower or says it would be impossible to make it faster, just mentions it's speed in passing), is beyond me.

Maybe cut down the snark?