

Ask HN: How would you defend Python against Node.js in a SaaS web app? - bcambel

Some folks at the office would like to use Node.js for a SaaS webapp, which I find extremely useless. We don&#x27;t except huge amount of customers, and we already have a WebSocket api written in Clojure ( which will change in the future, Node.Js might be a good fit here) .
What do you think Python&#x27;s biggest strength against Node.js ? First thing that come to my mind is the development speed, great open source projects, tools and huge community, years of experience, etc.. Help me out to support my argument.. 
All server side code will be in CoffeeScript( if node.js will be chosen )
Thanks
======
declandewet
I don't think any of those except "years of experience" are valid points
against the use of Node.js, and even that isn't really on the mark with
reality. This is because Age !== Experience. Perl has been around longer than
Python, but it sounds like you wouldn't want to use it. Granted, Node.js is
still considered _fairly_ new, but remember - it _was_ released in 2009. We're
a few months away from 2014, and this has been more than enough time for
Node.js to mature just enough to be suitable in a production web app.

I'm not advocating the use of one over the other for you (personally I'd go
with Node because my expertise in it outweighs my expertise in Python), I'm
simply stating my opinion that these are not valid reasons to disregard the
technology. The Node.js community is bustling, the amount of modules available
on NPM are in the tens of thousands, and many open source projects use it
(Yeoman, Grunt, Stylus, Jade, Roole, LESS, Bower, CoffeeScript to name a few).

Development speed is likely the most probable of your points, but even so -
you can write a Node.js app in CoffeeScript, which you might be more inclined
to do since your love of Python is so prominent, and CoffeeScript borrows many
ideas from Python, such as significant whitespace and chained comparisons. A
manual compile step isn't necessary as this feature can be done by most IDE's
implicitly. Express.js also helps big time.

The only reason I would use Python over Node (if I was in your position _and_
actually knew enough Python) would be if the web app in question required
intensive mathematical or scientific calculations - Python would shine over
Node in that respect.

------
staunch
I've found that, at the end of the day, choices of which technology to use are
rarely (but _certainly_ not never) actually technical decisions. You could
create this app with C-based CGI scripts if you really wanted to, and you
could probably make it work perfectly well.

Realizing that your decision isn't a technical one is the first step in
actually having a fruitful discussion. Arguing that you _can 't_ use any
reasonable technology is just going to turn into a pointless argument.

In my experience 95% of the time the right choice is whatever your team is
excited about using. The more excited and motivated your team is the more
likely you are to build something good, and that's what _really_ matters.

------
brianchu
_If_ you have a sufficiently JavaScript-heavy client-side codebase, there is a
very strong argument for essentially unifying the server-side and client-side
tooling. Being able to write and run unit tests in exactly the same way
(jasmine or mocha), being able to use the same IDE or text editor plugins,
being able to use the same package manager (npm), being able to move client-
side and server-side developers relatively effortlessly, being able to use the
exact same build tools (grunt or something else). You also get to share code
between the client and server (this isn't a huge benefit, though).

As a bonus you get the fact that node.js can scale better, though this should
not be a huge concern.

Python has a real advantage if you're doing lot's of data analysis / machine
learning, as the node.js ecosystem for those applications is nearly non-
existent.

------
amccloud
I'm a huge fan of Python. I've recently started to benchmark websocket
servers. Python (gevent, eventlet) completely locked up when I subjected it to
the load, ~30 frames per second, I was sending to a Node.JS and Go server. I
kinda expected that. Maybe i'm doing something wrong. For now I think i'll
stick to nodejs.

------
mattwritescode
Maturity, and development speed is what it comes down too.

(Development speed also includes support, and community willing-ness to help)

Its all well and good selecting a technology because its got a lot of hype at
the moment but what happens when you need to support, fix and maintain the
code.

Or even better debug the darn thing!

------
apphrase
Tools and community are the key, the rest can be argued for days or months or
years with no real winner nor real value to it...

