Live data from Hacker News

Python vs. Node vs. PyPy benchmarks

blog.kgriffs.com

51–57 of 57 posts

Re: Python vs. Node vs. PyPy benchmarks

#51
post #50

Red and green side-by-side on a chart... noo :( http://jfly.iam.u-tokyo.ac.jp/color/#pallet http://tools.medialab.sciences-po.fr/iwanthue/

IMO its a little bit excessive to ask that every graph generated is color-blind safe... Isn't there software for colorblind people to correct that? (Something that changes the palette of colors displayed...)

Red & green is the stereotypical colorblind test, that's a pretty obvious combination to avoid. It's easy to choose colors that are at right angles in the color wheel, and that's not how accessibility works - you can't require every paraplegic to have a special wheelchair that can climb stairs, despite it existing...

Re: Python vs. Node vs. PyPy benchmarks

#52
Things like this DO NOT MATTER.

Facebook was built on PHP and MySQL, both of which are awful pieces of crap.

Twitter went down like every week for a year. It was written on RoR by people who didn't really know RoR.

Meanwhile, a bunch of better engineers using better technology got their clocks cleaned while the winners eventually had so much money they could afford to hire an army of engineers to rewrite everything.

If you know Javascript really well, use Node (although I feel sorry for you). If you know Python really well, use Python (yay). If you don't know anything, well, pick something. If you are choosing a programming language because of how many QPS you can get on some trivial task, you are an idiot.

You know the graph I would like to see? A scatterplot of how good various startup founders and early team were on engineering vs finding a market fit, with the dots labeled with how rich they are now.

Re: Python vs. Node vs. PyPy benchmarks

#53
post #43

Earlier quoted context omitted.

I'll just throw a couple pet-peeves of mine in here: - No proper packaging/namespacing - Completely idiosyncratic results when operating with mixed data types (10 + 'p' = '10p', 7/0 = 'infinity' and all that) - Variables default to a pseudo-global scope - Prototype based 'inheritance', while cool, is just cumbersome and inelegant compared to languages that have proper object oriented language constructs - Take all th…

- No proper packaging/namespacing http://nodejs.org/api/modules.html - Completely idiosyncratic results when operating with mixed data types (10 + 'p' = '10p', 7/0 = 'infinity' and all that) I wouldn't call it idiosyncratic but just use Underscore and you are fine. - Variables default to a pseudo-global scope just use 'var' when declaring them - Prototype based 'inheritance', while cool, is just cumbersome and ineleg…

I don't mind languages using brackets. I used to do a lot of C and C# development and it never bothered me. The problem is that, at least to me, a Javascript code base of around 2000 lines already becomes unreadable, specially when you consider some common patterns like 'declare a function to define a namespace'. You normally end up with functions inside of functions, calling jQuery event handlers by declaring yet another inline function... By the time you use a 'for' loop, you already are 4 indentation levels/brackets in. Messy.

As you say, libraries work around a lot of these problems, but most of these workarounds are hacks. 'require.js', for example. And you shouldn't need to use underscore to get sane typing. About OO... It's debatable, I think languages like CoffeeScript and TypeScript have done a good job of abstracting the weirdness, but that's the thing: they are languages that compile to Javascript.

Anyway, I like Javascript, don't get me wrong, it's just that I don't think it's a great choice for big codebases. I know I get a lot of hate every time I say this, but to me Node.js is an excellent example of using the right tool for the wrong job. Had the energy been put behind developing the same concept as a library to a language with a decent standard library, so much work would've been saved 'catching up'.

Re: Python vs. Node vs. PyPy benchmarks

#54
post #17
post #3

Node/V8 is a beast and will dominate web development in few years. EDIT: Downvote me, I don't care.

If the web development industry moves from PHP to JavaScript as the main backend language... well, from quality perspective nothing will change. IMO.

While JS is quite flawed, it's nowhere near as bad as PHP. If JS kills all usage of PHP, the world will be a better place.

Re: Python vs. Node vs. PyPy benchmarks

#55
post #36
post #27

Earlier quoted context omitted.

Nope, I don't get any numbers/labels either. Seems like the website is incompatible with a bunch of browsers.

He's just using Flot, which a lot of us use for canvas-based charts. Do they work for you at all? http://www.flotcharts.org/ If not, what browser are you using? It would be nice to know if Flot is not compatible with something.

iceweasel 10.0.12 (basically the same as Firefox 10.0.12) It ships as the default browser for debian wheezy. The home page of flotcharts.org does work correctly.

I also tried Konqueror Version 4.8.4 (KDE's browser) and it didn't even display the graphs (not in the blog post or on flotcharts.org).

Re: Python vs. Node vs. PyPy benchmarks

#56
post #35
post #31

Earlier quoted context omitted.

This is my way to say several points: - If the majority of our industry can make the switch to JavaScript, they'll ruin it in terms of average code quality. - Even good, idiomatic JavaScript code sucks for reasons inherent in the language. - I wish people wrote just good enough Python or Erlang or Haskell or whatever code instead of excellent PHP/JavaScript. So yes, I treat PHP and JavaScript backend jobs equally. [E…

JS is a modern and beautiful language, comparing it with PHP is bold. People fighting Node are just afraid to change and to start from zero again, they fear the truth. No other language offers C-class speed, that rich ecosystem (which is fully async) paired with such an easy approachability plus the best and most modern package manager around. Speed is not everything but users won't tolerate unresponsive web services…

> deploying JVM based stuff (Clojure) is no fun at all).

In what world is typing "lein uberjar" and moving the resulting file to your webserver considered hard?

Re: Python vs. Node vs. PyPy benchmarks

#57
post #16

Earlier quoted context omitted.

Give Node s try before judging, Node gives you same productivity as other popular languages used for web development but with C-class performance

Ummm, where are you getting that node has C-class perf?

A quick google [1] results in this article. Look for JS:V8 - Node runs off of that. Most of the graphs I glanced at show it's very close to C. I glance because I've properly checked out other benchmarks which confirm this.

[1] http://attractivechaos.github.com/plb/

Post reply on HN