Hacker News new | ask | show | jobs
Node.js or Python/Django?
17 points by Zisko 4226 days ago
I've been using Node.js for quite a while and have become pretty invested. But I can't help but have a "grass is greener" feeling about python and Django. Python is just so much prettier than Javascript, but I feel like I'd be jumping off of the fast- moving node train! I am currently a senior CS student, so I'll also be looking for a job soon. Should I focus my time on python? or stay with node?
13 comments

Stick with Node because the job market is currently hotter for it, get into a hot startup to get practical experience and make some contacts, and then wait for the next technology cycle. I suspect that both Node and Django will be obsolete in roughly a year or two.

(My background: I started doing Java Swing before college; wrote a bunch of PHP in college; got my first job working on Java webapps with servlets and JSF; founded a startup that successively ended up using web.py, Pylons, and Django; got into Google where I ended up writing webapps in C++; participated in the rewrite of that C++ server in Java, and am now using straight Django for my second startup. The technology world really does move in cycles. Use whatever you're most familiar with, learn it well, milk all you can out of it, and then move on only when you have to. You can save yourself years of effort by avoiding the latest fad and "grass is greener" syndrome.)

> I suspect that both Node and Django will be obsolete in roughly a year or two.

Quite a bold statement about Django, which I can't agree with.

Django has bee around since 2005 - for 9 years. Longer than node.js lifespan. I don't really see any large competitors in the web framework field that would push Django from its current position.

Check careers.stackoverflow.com for jobs tagged with Django - quite a lot. That shows rather strong position of the framework on the jobs market. Those jobs may not be hip or not in startups, but nevertheless - they are there.

Anyway. Certainly framework fading away is not something new, but I would be surprised if that would happen to Django in the next two years. Five - possible. Two - doubt it.

By obsolete, he probably meant that new companies wouldn't be adopting it anymore, and that the only jobs left would involve maintaining legacy code.
I seriously doubt that.

There are new sites added to this index every day - https://www.djangosites.org/

Chess.com also relaunched using Django in their webstack.

I'd say that things are going to pick up for Django - they've got a solid plan moving forward and they can nip at rails devs by introducing websockets, SSE and WebRTC features which rails doesn't have (out of the box).

The main weakness for Django in my opinion is the community isn't as vibrant and energetic as it is with node or rails.

My own startup is using Django, so I'm certainly aware that there are new sites being launched with it every day. I was one of them last week. :-)

What I mean by obsolete is that it is no longer the hot new thing on the bleeding edge of technology. I chose Django because it wasn't the hot new thing; I'm already familiar with it, I've written a half dozen sites using it, and a general rule when founding a startup is that you shouldn't compound market risk with technical risk. Right now, my biggest problem is building a product that users want; I want the shortest path toward getting the big things right, not the sexiest little things.

But Django is definitely showing its age, and the environment has changed in ways that make you work around the framework instead of with the framework. Users are getting accustomed to logging in with Facebook or Google instead of having a separate registration system for each site; this is available with django-allauth, but then what's the point of having a built-in authentication system? Users are increasingly getting accustomed to direct-manipulation user interfaces instead of forms; Django has no support for that, and newer alternatives like Meteor beat the pants off it in that regards. Users are shifting to mobile; Django mobile support is spotty, largely provided by a set of sparsely-maintained third-party addons.

And then there are new technologies that promise to throw a huge monkey wrench into the web development ecosystem. Polymer & webcomponents are coming down the pipe, quickly; they introduce the idea of an application as a client-side set of individual downloadable components, which means that a lot of Django's routing, form, and templating infrastructure is no longer relevant. The increasing use of storage options other than RDBMS (Redis, Mongo, RethinkDB, protobufs or JSON on disk) makes the ORM less useful. JS-heavy apps shift the focus from building HTML quickly to building bundles of related JS functionality quickly, and Django has no built-in features for that. The most common solution, Bower, is pretty heavily tied to the Node.js ecosystem.

It should also be noted that node.js jobs are practically non-existent outside of the startup scene in tech heavy cities.

Best to do market research for the area one actually resides in, at least until you have enough experience to do remote positions.

'I suspect that both Node and Django will be obsolete in roughly a year or two' I don't see this happening for Django any soon. It is very mature and has a good adaptation rate.
Hard question, which I'm dealing myself too.

Right now I think you should concentrate on Node.js - finish your degree, maybe join some exciting startup or start something yourself. Keep looking at python from time to time. Maybe do some hackathons or tiny projects by yourself.

Node.js is certainly fast moving train. But where would it end up in? I don't really keep my hand on the pulse of the node.js community, but I'm not sure node.js is here to stay in the long run. Node.js will be used for various things for a long time. It has amazing websockets implementation, asyc execution does have some great benefits, but the code. My god is it messy. As mundanevoice points out below - you have to be a very solid and experienced developer to keep it all sane.

About python. I think it'll be around for a while. It is solid, it is readable, it is fast. Python community is large, there's a lot of very high quality tools written for it. It may not be so hip as node, but there's a lot of jobs for python devs out there.

All said, I myself is still torn about this question, though. I know both languages, but I've used node.js in more exciting projects than python. Python is so beautiful, but node.js stuff is interesting. So I'm still on the crossroads - which way I want to go all the way. And should I?

Python is a solid choice in the long run - it'll be around. Node.js? Most likely too, but for what purpose and how many companies would go with it?

This is awesome, Thanks.
It really depends on what you want to do. Python wins big with a wide and varied ecosystem outside the basic web domain. Do things like computational science, data analysis, mathematical modelling, statistics, GIS etc. sound like something you might want to get into? If so python is a much better bet. If ,on the other hand, you're happy in the web services domain where node has its main strengths, then node.js vs python pretty much works out to a draw and there is not too much reason to switch.
I am writing Python/Django professionally for two years now. I have also written some Node.js at work and Open Source. (https://github.com/vinitkumar/node-twitter). So, I think I would be able to give some advice.

Node.js is all cool to experiment with and build some projects but it gets incredibly tough when you want to write something complex. I am not saying that it is impossible to build something complex, but it would take a very experienced developer to do all of that in acceptable time.

Python/Django on other hand has a very mature ecosystem and the development is really fast as compared to Node.js which also has a fast start but you get stuck when you need to build something complex. There are many quality plugins for Python/Django which in IMHO much better in quality than npm packages.

Python on other hand is a better language than JS and you won't need to fight the language to write better code (The point is it is very easy to shoot yourself on foot while using JS).

If I were you at this stage of your career, I would suggest to start doing Python/Django and maybe learn some good Golang/C++.

There's absolutely no reason you can't be fluent in JS, Python and Ruby. Just try Python for your next project, then maybe try Ruby for the one after that. Or perhaps a functional language like Clojure or Haskell. Each successive language you learn will take about half as long as the last one, because you've accumulated the concepts and it's just learning more syntax.

Node may turn out to be a fad, so don't hitch your wagon to it fully. To be a good (web) developer you are often going to need to learn new languages and frameworks as the tech landscape changes.

I've programmed a lot in Python before I started using NodeJS. Once I got over the shock of the tangled mess that can be written in JS, I found NodeJS + NPM very productive. I've never grokked Django well enough to use it in production.

At this point in your career I'd suggest polishing your Node / JS skillz and make yourself valuable to a potential employer. Being so-so with Python (or any other language) is not likely to increase your value in the marketplace.

If I were in your situation, I'd sooner look at Go or Rust than Python, but only once you are earning good money.

I always hear people suggesting Go or Rust, but I have never seen a job advertised (in Europe). Am I just looking in the wrong places?
Rust isn't even stable yet, so there are very few companies using it in production. The ones that are tend to be pretty exciting, though. :P
I personally love the Python environment and community. There is very little you ever need that you can't find a module for. It is also a very well adopted language that many developers know and is increasingly popular in education so the amount of people using it is almost artificially increased. Django as a framework is used by a ton of big companies and sites and has proven itself to be very scalable and durable. Node to me is horrible just because of javascript, so take my bias with a grain of salt ;)
Why limit your choices to these two? There are more great frameworks and great languages. Ruby on Rails is an obvious candidate. Ruby is a lovely language and Rails is a solid framework, perhaps even the best web framework out there for many tasks. There's also plenty of demand for Ruby/Rails talent.
Scala!

You'll have the excellent Play Framework and Spray IO. WebJars, SbtWeb, and its plugins lets you add all sorts of goodness including calling nodejs stuff on your javascripts. And you won't stray too far from the JVM.

No harm to learning Python, especially when you are a student and have the time.

You need to learn multiple languages/platforms, and learn to use the best tool for the problem.

What is Node.js? It's an implementation of the Reactor pattern along with some package management capabilities plus a bit of hype:

http://en.wikipedia.org/wiki/Reactor_pattern

http://en.wikipedia.org/wiki/List_of_software_package_manage...

Both are possible in Python, while leveraging a MUCH better language.

If you have the time, don't jump into Django right away. Try Python without a framework first, if you have time.
This is a horrible question, why would you even ask something so stupid and mundane. If I were you I'd just give up and become a wordpress developer