Hacker News new | ask | show | jobs
by Something1234 2339 days ago
Your claims are without merit unless you post details about your setup and what you were trying to do.

Especially considering that there's quite a few sites which run entirely on Python.

3 comments

This claim is specifically related to blocking webserver in python vs concurrent webservers in go. I assumed this is common knowledge, that scaling python webservers is a complicated thing, while in go you get a concurrent web server in standard library,
Were you deploying using a Python webserver (e.g. SimpleHTTPServer), or was it nginx routed to an app server?
And this is the trouble with the OP imo. While its true, I find it an unfair comparison to make.
How about comparing a blocking server in Go versus the same in Python, then an async server in Python vs the concurrent Go server? That would be a more apt comparison.
That you can run a site entirely on Python does not mean it's efficient to do so.
Efficiency is measured in a lot of different ways. Development speed? Team familiarity? Existing infrastructure (private pypi etc...)? Existing libraries?

If we go with what I would assume is your definition -- speed of execution versus resources used -- it is certainly possible to build fast Python applications that are efficient.

But use what makes you and your team happy, life is too short for anything else.

blocking webservers are a common problem in Python. Even if you have async, all it takes is a CPU bound task or some sync IO deep in some third party library and its lights out for your server, and no debug info for you either.