Ask Hacker News: What Python web framework should I use? - <AUTHOR>

What python web framework would you guys recommend for smaller web projects? Examples would be a small blog engine, simple news site etc. Django seems quite huge for simple projects, so recommendations are more than welcome. <comment><USER2> I'm currently working with TurboGears. I evaluated pylons, django and web.py a year ago and made my decision. Here is a summary of my opinions (note from a year ago).

pylons: didn't really like the lack of decorators, didn't seem to be an ORM of choice, docs looked weak although the wiki was well stocked with recipies

django: really well documented. Seemed to be HUGE and I felt intimidated by it. It wasn't clear to me I could strip it down to what I needed. Didn't seem very modular, you can only use the Django ORM and templating engine.

web.py: Far to simple for my needs, you need to build nearly everything from scratch, simple to learn because there is nothing there!

I chose Turbo Gears because it seemed easier to chose the components you want to use. The idea that the TurboGears community picks best of breed python components and integrated them really appealed to me. This is both good and bad but in general I think it's been good for the project.

A year later and I haven't been disappointed. The TG community is really friendly as well :) TG is working with the pylons team for the next version of TurboGears and I know there has been a lot of code sharing between the groups.

That's my 2p, good luck.

<comment><USER3> "Didn't seem very modular, you can only use the Django ORM and templating engine."

Very common misunderstanding. You can use Django with SQLAlchemy (I have done in the past). You can use Django with Genshi, or Cheetah, or whatever template engine you like (I would strongly recommend using something like Genshi for outputting XML). It's usually better to stick with the Django ORM though as it will let you use many of the excellent extension applications for Django (such as django-mptt, django-tagging or the Django admin package). The same is not true for the Django template system - replacing it with something else has no disadvantages at all that I can think of.

</comment></comment><comment><USER4> I personally like web.py:

PROS: * Light and fast, * Really flexible, * Really easy to learn, * Easy to install, * Nice error reports (mostly copied from Django), * No database ORM

CONS: * No database ORM, just some helper functions: insert(...), update(...), select(...), etc. You must also build the DB tables by yourself. * Limited documentation.

<comment><USER5> I stopped using web.py after I had to correct Aaron when he recommended a 'session' implementation that had a massive gaping security hole.

[http://groups.google.com/group/webpy/browse_thread/thread/2f...](http://groups.google.com/group/webpy/browse_thread/thread/2fcbcb60a99a1c79/4d2a53b33adc3cdb?#4d2a53b33adc3cdb)

If he couldn't spot that when he posted, I don't trust him to spot any other problems with web.py

<comment><USER6> For a second I didn't get what the big deal was here. Sure you have to keep your pickled python objects in a secure place on your server. Sure you could have problems if someone could get at those, but they would need to crack your server first and then figure out how your app worked. If they could do that you're hosed anyway...

Then it hit me.

He was suggesting you give the pickled object back to the client _in the session cookie_ and load whatever the client sends later right back into the interpreter. Whee!

<comment><USER7> > He was suggesting you give the pickled object back to the client in the > session cookie and load whatever the client sends later right back into the > interpreter. Whee!

I've done that with _signed_ cookies.

<comment><USER6> I imagine you didn't store any per-session state on the server as well, so I'm curious about what you used to validate the cookie.

<comment><USER7> I secretly salted the cookie.

Think HMAC, though I used two completely different keys, rather than generating them from one key, added an optional step of appending the client's IP address after the first hashing (with the first key) and before the second one.

(The second hashing in HMAC is designed to prevent collision attacks (even on weak algorithms like MD5), since you'd essentially have to find a fraudulent input that collides _twice_ : once when hashed, and once more when its hash is hashed).

My implementation also allowed the data to span an arbitrary number of ~4kb cookies). Firefox maxed out at around 0.5MB, though if you're using that much session data, you may want to rethink your app design... ;)

</comment></comment></comment></comment></comment></comment><comment><USER8> Use Django for any web publishing app - blogs and news sites are its real strength. I'm using Django for what I would consider edge cases (eg building on-line databases) and it's not a perfect fit, although I think it will work.

If you learn Django, I'm sure you won't regret it. I don't think it's "huge" at all: it's compact and usable.

</comment><comment><USER5> I prefer Pylons. I've built all sorts of things with it:

* A RSS-rewriting, caching "proxy" for the News.YC feed

* A search engine for 2 gigs of email, going back to 1995

* A customized CMS-like app

* And now, my blog, which I'm almost done writing; I keep making changes to the architecture.

TurboGears 2, which some have recommended, is being built on top of Pylons.

</comment><comment><USER9> I like Pylons. I've used it for both big sites (<http://www.bittorrent.com/>) and small ones (<http://codepad.org/>), and it's been pretty good for both.

</comment><comment><USER10> In Django you could build the core of either of those two examples in an afternoon. I have done so just for practice. Yes, you won't use 90% of Django's potential. But the 10% you do leverage lets you build something like that very easily.

For a simple blog you would need to write only a few views and templates, and then I would use the the built-in admin system to manage the content. Same sort of situation for the simple news site.

I always get flamed for suggesting to not reinvent the wheel, but if you want to do build something like a quick news site, why not leverage all the pre- existing work you can. Technology is not your differentiating factor. /rant

</comment><comment><USER11> I hate the name, but I've been very happy with cherrypy. Some things seemed too big (Django, Turbogears) and I liked how cherrypy managed routing and config details more than I liked pylon's implementation.

</comment><comment><USER12> Whatever makes you happy and lets you get the job done efficiently.

Don't get stuck in paralysis through analysis. Find something that seems good and go with it.

</comment><comment><USER13> Pylons definitely

</comment><comment><USER14> django.

<comment><USER15> Could you explain why you would use django over the others? Does pylons have too much magic? I've never used django and am curious if you have used the other frameworks.

<comment><USER16> I have only used Django, Rails, CakePHP and raw PHP. Django has a superb ORM layer (beats Rails 10-0), where relations are really well implemented, as members of the model. Selects are easy, and can be chained (as filters). In Rails (even 2.0) I had to use find(:all, condition => <SQL fragment>. That is so not hiding the db layer. Generally, there is much less to none auto-magic. This is a thing I quite disliked in Rails, both as a beginner and beyond. I like to keep most things explicit. I find it baffling that Rails is considered easy to understand. Due to the auro-magic, I found the learning curve pretty steep.

</comment></comment></comment><comment><USER17> Django. You won't regret it! The url mapping, the views and escpecially the template engine is fantastic. Almost every element of Django behaves as it should be. Strict separation from code and layout for example.

</comment><comment><USER18> If you want to be adventurous, you can also look at Werkzeug (a collection of WSGI utilities) and choose whatever ORM (SQLAlchemy, SQLObject, etc) and template system (Jinja, Mako, etc) you want.

<comment><USER9> Pylons is also WSGI-based, and lets you use whatever ORM and templating components you want (although Mako is the default for templating).

</comment></comment><comment><USER19> For very small projects (i.e. only a handful of users, no serious performance requirements), I typically use web.py (<http://webpy.org>). It's very simple and offers only very basic functionality, but does a good job of staying out of the way and generally letting you do whatever you want. I've heard from friends that Pylons is also a good option, but I found it to be more complex than I really needed.

<comment><USER20> hi how can i reach u?

</comment></comment><comment><USER21> mod_python + mako

Edit: I started with Pylons but was simply overwhelmed by the complexity. I checked out but didn't use TurboGears and Django so I don't have to much to say about them. web.py is nice, but it's immature and some things don't seem to work the way they should.

So I rolled my own (if you can call it that) using the db module from web.py along with Mako and mod_python.

Yes before the WSGI zealots freak out let me say that it is NOT a WSGI solution but I could care less. It just works.

</comment><comment><USER22> For smaller web projects? <http://webpy.org/>

It's very simple, yet powerful enough to let you do pretty much anything you need to.

</comment><comment><USER23> Just as a warning. Its not listed here, but stay away from Zope3/Plone for a while :).

<comment><USER24> Why, may I ask?

I'm contemplating to skip Zope3 to learn Plone. I'm also tinkering with the idea of purchasing Plone 3 book by Martin Aspelli. I heard the book is good and it gives you enough information about Zope3 to learn Plone.

<comment><USER23> I wrote a lot about it in a blog post this summer.

[http://thingsilearned.wordpress.com/2007/08/14/zope3plone- to...](http://thingsilearned.wordpress.com/2007/08/14/zope3plone-to-django/)

Its a great CMS with a lot of awesome features. Its just incredibly difficult to pick up and work with, especially in its current state.

</comment></comment></comment><comment><USER25> well django is definitely a good starting point.. but turbogears has very advanced templating engine... but for a beginning (like yours truly), django is very easy to setup and get it running..

</comment><comment><USER26> django. this isn't an even reasonable question to be asking.

<comment><USER27> It's reasonable to try to narrow the landscape down. There's a lot of information out there.

Although I agree, Django is really your best choice here.</comment></comment>


AOL and Yahoo in merger talks - <AUTHOR> http://www.guardian.co.uk/technology/2011/sep/09/aol-yahoo-reported-merger-talks

<comment><USER2> Two wrongs don't make a right.</comment>


Ask HN: Best cheap hosting options for Node.js apps - <AUTHOR> Hi guys! Just want to know if where can I host my Node.js app at cheaper price rate?<p>Suggest some good options. <comment><USER2> Digital Ocean has a $5/mo VPS instance. OVH has a ~$3.75/mo VPS instance.

</comment><comment><USER3> scaleway has an arm dedicated server with 3 euros per month

<comment><AUTHOR> yes! This seems really a good and reasonable option in comparison to Heroku as Heroku's pricing is a bit more high for a startup app like mine. Thanks for suggesting it.</comment></comment>


Colonel Edward A. Deeds–An able man who made things work - <AUTHOR> http://www.daytoninnovationlegacy.org/deeds.html <comment><AUTHOR> After reading this I was left wondering if there are still people like this today? I do not deny that we do have inventors, innovators, engineers, leaders and other professionals today, but to me it seems like now people are more singular in what they excel in. Colonel Deeds, in my opinion, was adept at multiple different skill sets, the best of which was realizing when someone else was better suited to the job and then providing them with everything they needed.

Some further reading is available at Wikipedia : [https://en.wikipedia.org/wiki/Edward_Andrew_Deeds](https://en.wikipedia.org/wiki/Edward_Andrew_Deeds)</comment>


Ask HN: Where do I get an Android app icon? - <AUTHOR>

My app desperately needs a new icon but I'm having some trouble finding a good designer. Where should I look for one? Ideally the icon would be in vector format.
I've already asked some random designers I've found on dribbble, but their price suggestions have been rather unrealistic. How much should I expect to pay?
I've also tried 99designs and that was a total disaster. <comment><USER2> You can try GraphicRiver's item request forum: <http://graphicriver.net/forums/topic/item-requests/42>

I'd be curious to hear more about what happened with 99designs.

</comment><comment><USER3> I recommend Guenther over at <http://www.androidicons.com/> — great guy, excellent work, and very reasonable prices. He will work with you and sketch out a brand new icon.

</comment><comment><USER4> Can you please share the price suggestion you had from dribbble's designer?

<comment><AUTHOR> Some offers have been as high as 2000$.

</comment></comment><comment><USER5> Do you have a link to your app and the 99designs contest?</comment>


Ranchero Software: Evergreen - <AUTHOR> https://ranchero.com/evergreen/ <comment><USER2> This is great news. I still use NetNewsWire 3.3.2, one of the finest Mac apps I have ever purchased. I look forward to seeing Evergreen evolve into a worthy replacement.</comment>


Personal Cell Phone Jammer, $27.41 - <AUTHOR> http://www.dealextreme.com/details.dx/sku.4355~r.51715689 <comment><USER2> Probably beyond the abilities of a typical hobbyist: <http://www.ladyada.net/make/wavebubble/index.html> but since this is _Hacker_ news.

<comment><USER3> Limor is a first-class hacker and this is a first-class hack. I was present when, a couple years back, she used her Wave Bubble to prevent interruptions to a wedding ceremony. It worked perfectly, and upon shutting off the jammer, there was the sound of voicemails arriving to a number of the guests. Bullseye.

</comment></comment><comment><USER4> These are apparently illegal to use in the U.S.

<http://www.nytimes.com/2007/11/04/technology/04jammer.html>

<comment><USER5> And for good reason. Who wants to have their cell phone rendered useless just because they happen to be standing too close to someone who decided they're more important than everyone else around them.

<comment><USER6> Similarly, it's a good thing dangerous chemical kits are outlawed in the US. Who wants to have their house burned down just because they happen to be living too close to someone who decided they're more important than everyone else around them?

update: Hey, why am I being voted down? Not trying to be a douchebag here. I really do view EM freedom as strongly correlated with normal-speech freedom. "Pirate" radio stations anyone?

Clamping down on "rogue" EM radiators is like clamping down on "rogue" anything else. We need a broader definition for "freedom of speech". EM is speech, too.

<comment><USER7> 1) Unless you're really trying, it's pretty difficult to burn down the neighborhood with a science kit. When using a cell phone jammer it's pretty hard _not_ to affect all the people around you. That's kinda the point. Now, if you don't want cell phones used in some place that you own, then paint the walls with signal-blocking paint.

2) Have you tried to buy a chemical kit lately? They took out all the fun stuff years ago.

</comment></comment></comment></comment><comment><USER8> I have this sitting on my desk right now. I got it a year ago. Unfortunately it doesn't work, or I'm too dumb to get it to work, but other people on the DX forum mention that you have to tweak it. Anyone want to buy mine and give it a shot? $20 shipped in the US. I'm serious.

</comment><comment><USER6> Coincidentally, I received two envelopes from DX today! I love that site and would like to vouch for their legitimacy. However, do be careful - if it seems too cheap to be possible, it's probably fake, just like my "Sandisk" Micromates microSD USB adaptor which is rather different from the Australian- bought genuine article sitting next to it.

</comment><comment><USER9> Way cooler: <http://www.ladyada.net/make/wavebubble/index.html>

</comment><comment><USER10> Instead of jamming the signal, how about spoofing the various protocols (i.e. make a micro-cell), but one that will connect all calls with silence.

Would take much less energy, since all you need is to be slightly stronger than the cell tower, plus you don't need to transmit all the time, just when there is a call.

For extra points, detect and forward calls to 911.

<comment><USER7> Huh? How exactly did you conclude that it would take less energy to build a fully functional mobile cell phone tower that supports a variety of incompatible protocols, all of which are secured with non-trivial encryption?

Even without the encryption, it is extremely difficult to demodulate a GSM signal

<comment><USER10> Perhaps you have a different meaning of the word energy? It will certainly take less radio energy to do what I suggested.

And as for GSM, have a look at [http://mobile.slashdot.org/story/09/08/17/0014235/Open- Sourc...](http://mobile.slashdot.org/story/09/08/17/0014235/Open-Source-GSM- Network-At-Dutch-Hacker-Convention)

<comment><USER11> Perhaps he interpreted your comment to mean "less energy for the hacker to build" rather than "less battery power for the device to operate."

<comment><USER7> Indeed. And I'm not convinced it would take less battery power to build a working cell tower.

</comment></comment></comment></comment></comment><comment><USER12> Does anyone know how to make a cellphone _booster_? I'd love to be able to get a bit more range out of my cell...

</comment><comment><USER13> I bet a ton of highschool professors wish they had one of these.

<comment><USER14> Apparently they are in wide use in Chinese and Indian schools.

[http://pcworld.about.com/od/wirelessphonesvoip/Should- Cell-P...](http://pcworld.about.com/od/wirelessphonesvoip/Should-Cell-Phone- Jamming-be-L.htm)

</comment></comment><comment><USER15> I went ahead about bought one right-away.

</comment><comment> onreact-com Does selling products on HN conform with the TOS?

<comment><USER16> It seems unlikely that the poster is the one selling this item. It seems more likely that the reason for posting this was to show that you can in fact now buy cell phone jammers for only a few dollars. This is quite interesting whether or not you actually want to buy one :)

<comment><USER17> While I'm not begrudging, it should be noted that DX links ending with ~r. and a number are affiliated to a particular user's account.

<comment><AUTHOR> Oh -- sorry about that! I found it through stumbleupon and didn't realize there was an affiliate link at the end. It won't let me change the URL now though.

<comment><USER17> No need to apologize even if you did do it yourself. I checked your previous submissions and it is obvious you are not spamming HN. There is no shame in linking to a interesting product using an affiliate program. You are technically advertising for them after all and deserve a payment.

I do wonder how much you earned the Stumbleupon user though. A quick google search on the affiliate suffix shows he links to a few other DX products on SU and elsewhere. Today I'm sure he saw a boost in profits.

</comment></comment></comment></comment></comment><comment><USER18> This is more badass:

[http://www.amazon.com/Uranium- Ore/dp/B000796XXM/ref=cm_cr_pr...](http://www.amazon.com/Uranium- Ore/dp/B000796XXM/ref=cm_cr_pr_product_top)

<comment><USER19> This product is called "Uranium Ore"... There is an interesting/funny comment, though.

Kyle J. Von Bose says:

 _I bought this to power a home-made submarine that I use to look for prehistoric-era life forms in land-locked lakes around my home town in Alaska. At first I wasn't sure if this item would (or could) arrive via mail, but I was glad to see it showed up with no problems. Well, almost no problems.

Unfortuantly my mom opened my mail, because she does not respect people's privacy. She was pretty upset to see Uranium Ore. After a long argument and me running away from home again, she finaly stopped being such an idiot and I was able to get back to work.

The quality of this Uranium is on par with the stuff I was bying from the Libyans over at the mall parking lot, but at half the price! I just hope the seller does not run out, because I have many projects on my list including a night vision sasquatch radar, an electromagnetic chupakabra cage, a high velocity, aerial, weighted Mothman net and super heated, instant grill cheese sandwhich maker._

<comment><USER20> he has two more:

<http://www.amazon.com/gp/pdp/profile/A2BC94DUL2FII7>

</comment></comment></comment><comment><USER20> Wait until you own up to having this thing and using it, you'll find yourself waking up in hospital wondering why.

<comment><USER21> What do you mean? That the device will make you sick or somebody else will beat you up?

<comment><USER20> You are interfering with the ability of others to communicate, it is the same as gagging everybody around you, which is about as rude as you could possibly get.

When somebody wonders out loud why their cell doesn't work, especially if the call they need to make is an urgent one and you whip out your 'gadget' be prepared for nasty stuff to happen to you.

Interfering with any kind of communication is about as low as you can go in my book (other than doing violence to other people), doing it on the sly makes it one step worse.

<comment><USER22> Talking loudly on a cell phone, oblivious to the tranquility you destroy around you -- that will come pretty close.

I'd like to think restaurant patrons and mass transit commuters had consideration for others (and the presence of mind to talk quietly) but they often don't. Jamming is probably not a good solution, though.

<comment><USER20> Society is about playing nice. To talk loudly on a cell phone is not nice, jamming isn't either (and illegal besides).</comment></comment></comment></comment></comment>


The Emularity - <AUTHOR> http://ascii.textfiles.com/archives/4546 <comment><USER2> "This means that somewhere, this instance needs to be connected to a proxy server, which assigns a 10.x.x.x address to the "Windows" machine, and then forwards the connections through. Basically, world's weirdest, most hipster ISP on the face of the earth."

I wonder if there will ever be a business case for things like this. I sit across the hall from a startup that sells mp3 gramaphones, etsy is a huge success, there are strange Kickstarter projects every day. Is nostalgia a permanent long tail phenomenon, or a fad from which people will move on?

<comment><USER3> There's no doubt in my mind that nostalgia is a permanent phenomenon. Spencer wrote _The Faerie Queene_ in deliberately antique english to appeal to people's nostalgia. And that was more that 400 years ago. There's been a market for classic cars almost as long as there's been cars.

How many businesses will carve out a niche in long tail tech is harder to tell. I expect it will be like many things, many enter, few leave.

<comment><USER4> Nostalgia might be a consistent phenomenon, but surely what we are nostalgia about changes. A 20 year old likely never experienced Windows 3.11 in the first place. That would likely make them view emulating it more of a novelty exercise than a nostalgic one, which anecdotally is a weaker and shorter lived motivator.

<comment><USER5> On the other hand, a 20-year-old probably didn't grow up with a record player but suddenly vinyl is in a huge renaissance.

<comment><USER6> On the other other hand, Vinyl at least has some upsides. Listening to a Vinyl is an experience, plus it's lossless, and physically owning a record is cool/makes good art/conversation pieces. Windows3.11 would be interesting to check out, but it'd be more like something you'd check out for 20 minutes to see how it used to be done, then you'd go back to your modern OS. Vinyl is an experience, most older software is a novelty.

<comment><USER7> On the other other hand, Windows 3.1 has some upsides. Running Windows 3.1 is an experience, plus it's on DOS, and having a Windows 3.1 install on your laptop is cool/makes good art/conversations pieces. Vinyl would be interesting to listen to once or twice to show off to your friends, but it'd be more like something you'd set up once to see how it used to be done, then you'd go back to an iPod. Windows 3.1 is an experience, vinyl is a novelty.

<comment><USER8> I think the closest equivalent to the claim that vinyl is lossless would be that Windows 3.1 is efficient. Well... sure... if you squint hard enough and tune the definition of lossless/efficient properly, sure... but not in an actually _relevant_ manner.

<comment><USER7> Windows 3.1 is on DOS, so it is lossless. There's no intermediary between any program and any other program. Everything runs in pure, unadulterated Ring 0, raw, unprocessed 16 bits.

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER9> Jason Scott is such a weird and wonderful person. I highly recommend watching BBS: The Documentary. Episode 8 was especially interesting and moving in a way I didn't expect. I would say, in brutal honesty, the production values are (unfortunately) low, but the content is pure gold, and well makes up for it.

So my thanks go out to Jason Scott and the small crowd of computing historians he unofficially represents. As a modern software and hardware engineer, it is both a joy to watch the old, and a comfort to know our work of today has a chance of being preserved in the years to come.

<comment><USER10> Nope, I'm going to do it, I'm going to focus right on one sentence and ignore all the compliments.

The BBS documentary was shot across 4 years on my own dime (no crowdfunding, my family helped pay for the camera) and traveling to 20 states, from 2001-2004, and then released in 2005. (10 years ago). This means some footage was shot as long as 14 years ago.

"Production Value" is a very specific term - it is almost always used to indicate skill or attention to the final product. All along the way for the BBS Documentary, I had to make choices. Remember, the Canon XL1 I shot with cost me $4000 in 2000, when it was bought. And instead of going with a handful of people, say, under 15, to tell the whole story, I chose instead to interview 201 people. This meant that sometimes in a single day I'd drive to up to 4 different homes, with miles between them, set up all the equipment myself, conduct the pre-interview and interview, and then move on to the next location. In one case I drove 500 miles to grab an hour interview with a figure who had popped up, and then drove back.

This was before DSLR became prominent, before HD was the norm. I could have gotten a full crew, but everything else would have suffered: the breadth of subjects, the locations, the variant voices. It's a choice I'm fine with.

I recognized, after BBS Documentary was done, that I'd want to move to HD, but in 2006, when I started filming GET LAMP, that cost me $10,000. I paid larger numbers for the new movies - $20,000 for the DSLR equipment. (Both GET LAMP and the new films are crowdsourced, based on the reputation of BBS Documentary.)

Choose your words carefully, please. I'll take "Dated", I'll take "SD", I'll take "Videotaped", but please don't imply I didn't sweat bullets over every aspect of the production, and that everything in there wasn't a best-of-all- circumstances choice made with the intent of finishing a project that many (at the time) thought was impossible.

<comment><USER11> As someone who liked your documentaries, I think you're misinterpreting the previous poster. 'Production values' doesn't refer to skill or attention - those qualities are clearly present in your work. It just refers to those aspects of a work which are simple functions of money spent. To say your work has low production values, then, just means you clearly didn't have a large budget, which is true but nothing to feel bad about - you did a great job with the resources you had.

<comment><USER10> I'm hoping that's the case, and I'm sure I'm oversensitive on this topic. It's just that subject was particularly important to me, and any impression that I didn't care so much about capturing that story before the chance to get the story was over just makes me over react.

</comment></comment></comment></comment><comment><USER12> If anyone is interested, I just wrote a simple guide on how to get your own DOS programs up and running with em-dosbox: [https://csl.name/post/em- dosbox/](https://csl.name/post/em-dosbox/)

Em-dosbox and emscripten are really amazing projects. An emulator is cross- compiled to JavaScript, which is then JITed in your browser's js VM. It's not only amazing that it works, but also that it runs pretty well (compared to native dosbox, it's only a little bit slower on some programs).

<comment> iso8859-1 how do you think em-dosbox compares to jsdosbox?

<comment><USER13> I like that it we can use either zip archives or img files with jsdosbox-- and that the setup is pretty straightforward.

Here's a guide I hacked together a couple of months ago for comparison: [http://atechdad.com/how-to-jsdosbox/](http://atechdad.com/how-to-jsdosbox/)

<comment><USER14> em-dosbox uses emscripten's packager by default, but it doesn't have to. Anything that can dump files into an emscripten virtual filesystem will work. The Internet Archive's loader uses .zip file bundles via BrowserFS: [https://github.com/jvilk/BrowserFS](https://github.com/jvilk/BrowserFS)

</comment></comment></comment></comment><comment><USER15> _it's running inside the EM-DOSBOX system, since Windows 3.x was essentially a very complicated program running inside DOS. (When Windows 95 came out, a big deal was made by Gates and Co. that it was the "end" of the DOS prompt, although they were seriously off by a number of years.)_

Nitpicking just a little bit: Windows 3 didn't run _inside_ DOS. Maybe "on top of it" if you want to put it that way, but not "inside".

It changed the processor and graphic modes and when shut down it reverted to the prompt. But by no means was it "just a big DOS program".

Guess what: Windows 95 _also_ was a program running "on top" of DOS. That was somewhat hidden, but I remember clearly that I booted to DOS and then executed either Windows 3 or Windows 95 (I was programming a compatible 16/32 bits application). There was some tweaking needed but it worked nicely.

<comment><USER16> It gets a bit metaphysical at some point, but 'on top of' or 'after' probably are better prepositions to use when describing the relationship between DOS and Windows.

'Instead of' would also work, in the case of Windows 95, as it would be fair to say that simply exiting Windows involves resetting everything back to the way DOS had it, then rerunning DOS.

And when you ran DOS inside a window in Windows 95, then that was DOS running inside of a VM.

<comment><USER15> I'm not sure but it seems my point has been lost in the way.

DOS is a real mode OS. Windows 95 is a protected mode. Windows 3 was some kind of dumbed-down protected mode that 286 had. Actually I believe it could work in different modes.

The distinction is pretty important. Windows 95, that needed a 386 minimum, was a true protected mode system, with virtual memory and pre-emptive multitasking. It would be absurd to call it "a DOS program" just because you could launch it from the DOS prompt.

So the same can be said of Windows 3. It changed processor mode, not so radically as 95, but enough to exit real mode... calling it "just a DOS program" is simply wrong.

</comment></comment></comment><comment><USER17> I'm waiting for the day that the wikipedia entry on windows 95 let's you load up windows 95.

<comment><USER18> > I'm waiting for the day that the wikipedia entry on windows 95 let's you > load up windows 95.

We'll have the technical side of this solved before the legal side is.

<comment><USER16> The legal problem is already solved, in a narrow sense, for programs which are otherwise impossible to install in the usual manner: [http://archive.org/about/dmca.php](http://archive.org/about/dmca.php)

Does Windows 95 qualify? Probably not quite yet, but if UEFI ever wins to the point where motherboards with the traditional BIOS become unavailable and then the available UEFI motherboards stop including a BIOS-compatibility mode, then it probably will.

That said, there's no reason why Wikipedia editors can't embed the player that Archive.org uses for console/arcade/dos games into their respective Wikipedia pages. It wouldn't be quite as easy as embedding a Youtube video (where every video gives you a snippet of HTML to paste into your page), but the emulator is just a js file, and the game is just a couple of small image files which you load and stick into the emulator's in-memory filesystem.

See [https://github.com/db48x/emdosbox- loader](https://github.com/db48x/emdosbox-loader) if you want to see how Archive.org is currently loading those. It's not quite ready to just be plugged in everywhere, but I'm working towards that possibility.

</comment></comment></comment><comment><USER19> > It turns out a number of fundamental aspects of The Web have changed since > this time.

I wish they went into more detail what exactly changed and why these browsers no longer work, unless it was the PPP protocol they mentioned that is causing the issue.

<comment><USER20> Original author of the hack here. Several changes:

1) HTTP 1.0 vs 1.1 and lack of the Host: header, as you've all deduced

2) Additional encoding info tacked on after the Content-type causes parsing issues

3) Many sites now redirect to HTTPS by default. While Netscape 1.0 and Mosaic 1.0 both support HTTPS, it used SSLv1, and well, remember POODLE? :P

Newer versions of these browsers tend to work in native DOSBOX but present problems when running on the web. We're working on it.

Biggest problem right now is that the virtualized dial-up ISP is a bit flaky. For some reason PPP over TCP over Websockets via Trumpet Winsock isn't as rock solid as it should be :P

<comment><USER21> And once you get past all that, the JavaScript that's so pervasive these days wont run in those ancient browser. My Mac Centris 610 has problems with all those tracking scripts everywhere.

</comment></comment></comment><comment><USER22> Imagine if they get to windows XP and ie8. We will never get rid of them!

<comment><USER23> Maybe all the emulators will have blocks in place, denying you ability to run WinXP and IE6 for Planetary Security reasons?

</comment></comment><comment><USER24> I recall running Windows 3.11 on a Mac using the earliest versions of Connectix Virtual PC in the late 90s. It was so slow as to be unusable. And today we can run Windows 3.11 in a browser. Mind-boggling.

<comment><USER25> I do too and it was almost useable...

Although Connectix also sold a playstation (original) emulator for mac that worked pretty well. Connectix was embroiled in a lawsuit with Sony, till Sony ended up buying it.

[http://en.wikipedia.org/wiki/Connectix_Virtual_Game_Station](http://en.wikipedia.org/wiki/Connectix_Virtual_Game_Station)

Part of the problem I think with some emulation speed has to do with bit order of the original hardware (or endian order) which makes emulators do a lot of memory moves.. We ran into this a little when looking into migrating software from PA-RISC to X86..

</comment></comment><comment><USER26> This prediction is becoming true day by day:

[https://www.destroyallsoftware.com/talks/the-birth-and- death...](https://www.destroyallsoftware.com/talks/the-birth-and-death-of- javascript)

</comment><comment><USER27> My first thought on reading this is that we can't be that far off from running MAME and every classic arcade game in a browser. Googled it and sure enough - it's already here courtesy of the Internet Archive:

[https://archive.org/details/internetarcade](https://archive.org/details/internetarcade)

<comment><USER28> The vast majority of the games will not run at a playable speed. Heck, a fairly large percentage don't even with the MAME software itself on 4Ghz+ CPUs.

MAME's commitment to accurate emulation is amazing.

<comment><USER29> He said classic arcade games, which we'll put at the early 80's. Those have been working in in MAME since the Pentium II days.

<comment><USER28> That's actually not entirely true. There are some classic games that still have run super slow until recently.

Pac Man/Ms. Pac Man comes to mind. Donkey Kong too.

Emulating analog audio circuits accurately requires higher math functions executed millions of times per second. Some of the oldest classics run super slow on sub-3Ghz CPUs.

</comment></comment></comment></comment><comment><USER30> There's another JS port of dosbox (via Java and GWT) - jsdosbox here: [http://sourceforge.net/projects/jsdosbox/](http://sourceforge.net/projects/jsdosbox/)

with a playable demo of doom here: [https://jsdosbox.appspot.com/](https://jsdosbox.appspot.com/)

</comment><comment><USER31> Who creates an emilator for Windows 3.11 and doesn't install the ski game?

<comment><USER32> 'the ski game' is likely Ski Free. Delightfully, the author has created a 32 bit version of the game, if you want to run it on your modern desktop. You can also download the 16 bit original version.

Considering the simplicity of his page, and the browser now running in the emulator, it should be possible to download and run the 16 bit version from his website:

[http://ski.ihoc.net/#download](http://ski.ihoc.net/#download)

<comment><USER31> That's just great! Thank you.

</comment></comment></comment><comment><USER33> Now I'm imagining pointing this thing not at a proxy that accesses the live web but one which picks a date in the wayback machine and relays the state of the web at the time the browser came out...

</comment><comment><USER34> I went through the period of nostalgia and fascination the author exhibits years ago with Amiga, c64 and dos emulation and virtual machines.

It's impressive and convenient that this runs in a browser, but does itreally change anything about emulation? We've had this capability for windows, mac and Linux for years which covers about every platform with a browser. I suppose it's convenient if you wanted to emulate windows 3.1 on your iOS device.

<comment><USER35> _> We've had this capability for windows, mac and Linux for years which covers about every platform with a browser_

Yes, but that always required installing emulation software, tracking down the necessary ROMs/disk images, etc. If it's running in the browser, the site admin can do all that once for everybody rather than every user having to do it for him/herself. All the user has to do is open a URL.

<comment><USER36> > All the user has to do is open a URL.

I think it is a shame that Java Web Start style tech never got anywhere. It pretty much delivered such experience (click url and app launches) without actually binding the application to the browser.

</comment></comment></comment><comment><USER37> They should try getting a more modern browser on there. If I remember correctly, while running my hand-me-down Gateway 2000 with Windows 3.11 in 1998, I managed to get Internet Explorer 3 or 4 installed after I downloaded it at a friend's house.

<comment><USER10> The goal is to add more browsers when this finally goes on the Internet Archive, yes.

</comment></comment><comment><USER38> Ok, I understand how you'd run a CPU emulator written in JS, in a browser, but how do these things get raw socket access?

If you're running in a browser, all the network access you get is HTTP AJAX, right?

<comment><USER39> No, there are various other mechanisms now, perhaps the most useful and widespread for this situation being WebSocket. It's not without limitations though: [http://en.wikipedia.org/wiki/WebSocket](http://en.wikipedia.org/wiki/WebSocket)

And it's not quite "the browser" in the usual sense, but Chrome Apps (and, I believe, extensions?) get access to TCP and UDP APIs: [https://developer.chrome.com/apps/app_network](https://developer.chrome.com/apps/app_network)

<comment><USER38> But websockets doesn't give you raw tcp, right? Do they have a proxy somewhere?

<comment><USER20> Not really a proxy - it's pppd in Linux with a vty redirected to a socket. More like a cloud-based dialup ISP that tunnels over existing connections than a proxy.

</comment></comment></comment></comment><comment><USER40> This looks like a weaker version of [http://copy.sh/v24](http://copy.sh/v24) with emscripten. Still a very interesting development though

</comment><comment><USER41> Is there a link to a live demo?

<comment><USER42> [https://twitter.com/textfiles/status/558625345029820416](https://twitter.com/textfiles/status/558625345029820416)

> Before I get 1,000 "GIMME DER SAUCE AND WHERE DO I KLIK" \- the DOS > situation showed me we need something to be really tested to go big.

</comment></comment><comment><USER43> Windows 3.1 was the pinnacle of Windows -- seriously I think they went in the wrong direction with 95 and we may never recover.

</comment><comment><USER44> K so JS is the new de-facto interpreted machine-Latin. The lingua franca.

Is there something else I'm missing here? We've known that there is a decent mapping from X86 assembly to a subset of javascript for a number of years now. You can even run the entire OCaml stack in the browser, or Doom, or Quake... etc. What's next? Wordperfect in the browser? Visicalc? This is clever and kudos to the guys, but how is this advancing what we already know?

Javascript is fast and flexible. The browser is a credible platform technologically. We can treat it like a VM. Yep...Got it. More than three years ago. [https://github.com/kripken/emscripten/graphs/contributors](https://github.com/kripken/emscripten/graphs/contributors)

<comment><USER20> WordPerfect in the browser? Please, that was so two weeks ago: [https://archive.org/details/msdos_wordperfect6](https://archive.org/details/msdos_wordperfect6)

Might need to print this and tape it to your keyboard though [http://bit.ly/1zDZrjk](http://bit.ly/1zDZrjk)

<comment><USER44> I'm waiting for vim in the browser... oh wait...

[http://dailyjs.com/2013/12/13/vimjs/](http://dailyjs.com/2013/12/13/vimjs/)

Still - I'll take it all back when someone shows me Wordstar.js. Who needs Indesign??</comment></comment></comment>


The /bin/true Command and Copyright - <AUTHOR> http://trillian.mit.edu/~jc/humor/ATT_Copyright_true.html

<comment><USER2> Alas, this is almost off-topic but I'll mention it anyway. This is part of the "Reporting Bugs" section of the GNU /bin/false command:

        REPORTING BUGS
        Report false bugs to firstname.lastname@example.com

I love commands with pesky names.

</comment><comment><USER3> While looking for the GNU true source code I found that raganwald has blogged about this earlier. His conclusion seems sound: [http://weblog.raganwald.com/2008/02/recursive- implementation...](http://weblog.raganwald.com/2008/02/recursive- implementation-of-bintrue.html)

The source code is in this Daily WTF thread: <http://forums.thedailywtf.com/forums/t/3779.aspx>

</comment><comment><USER4> There are two things that should be note about copyright, which would have prevented AT&T or anyone else from actually enforcing any copyright on such simple files.

First, copyright does not protect ideas--it only protects the way an author expressed the idea. The closer the expression is to the minimal way to express the idea, the less likely it is to be copyrightable. In the case of the simple implementations of /bin/true and /bin/false, they are pretty darned close to minimal.

Second, if you have author X who produces a copyrightable work, and author Y who later independently produces a work that happens to be identical to X's work, but Y did not copy elements from X, Y is not infringing X's copyright.

This second case doesn't happen often. If someone were to decide to write a novel about boy wizards, and produced something identical to the first Harry Potter book, no one would believe that they did this without copying from Rowling. However, if the work is small enough, an identical independent work is believable.

In the case of the simple /bin/true and /bin/false, a defense that you didn't copy from AT&T would be believable. Even if you admitted you looked at the AT&T source or had it described to you, it would be believable that you produced your own expression of the idea of "a do nothing shell script" and a "shell script that exits with status 255".

</comment><comment><USER5> For comparison, here is /usr/bin/false from my Solaris box:

      $ cat /usr/bin/false
      #!/usr/bin/sh
      #       Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
      #         All Rights Reserved

      #       THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T
      #       The copyright notice above does not evidence any
      #       actual or intended publication of such source code.

      #ident  "@(#)false.sh   1.6     93/01/11 SMI"   /* SVr4.0 1.3   */
      exit 255

You'll notice the slight difference with `true`.

</comment><comment><USER6> Did AT&T actually tried to enforce this copyright? Because what I see is auto- generated header that is put to every shell script present on the system. Entertaining nonetheless.

<comment><USER7> Yes your are surely right. But what about GNU guys' bint/true implementations copyright message? :)

<comment><USER8> The GNU /bin/true is almost certainly complex enough to qualify for copyright.

<comment><USER9> This is GNU's _Appropriate Legal Notices_ as required by section 5d of the GPLv3:

      An interactive user interface displays "Appropriate Legal Notices"
      to the extent that it includes a convenient and prominently visible
      feature that (1) displays an appropriate copyright notice, and (2)
      tells the user that there is no warranty for the work (except to the
      extent that warranties are provided), that licensees may convey the
      work under this License, and how to view a copy of this License.  If
      the interface presents a list of user commands or options, such as a
      menu, a prominent item in the list meets this criterion.

</comment></comment></comment></comment><comment><USER10> Reminds me of Oracle licensing the Java Hello World: [http://docs.oracle.com/javase/tutorial/getStarted/applicatio...](http://docs.oracle.com/javase/tutorial/getStarted/application/examples/HelloWorldApp.java)

<comment><USER11>
      # (c) 2012 me
      #
      # The following comment is tried to be copyrighted
      # by me. Do not misue!
      #

      awesome

<comment><USER10> # Can I use derived works?

Yeah, super awesome!!

</comment></comment></comment><comment><USER12> A couple of things,

As many know the #ident tag in 'C' code was used with SCCS (pre-cursor to git/svn/cvs/etc) to create a string in the 'binary' which identified the code. In shell scripts it just sat there.

The change in the ident string where it gets the 'SMI' is when the version was from 'Sun Microsystems Inc' (aka SMI).

The reason Solaris included it was because it was part of the 'merge' between SunOS and System V and Sun had permission to all of the AT&T copyrights with respect to UNIX once they became 'partners' (AT&T invested essentially a billion dollars in Sun).

</comment><comment><USER13> This is an interesting idea. If John Cage composes a song that is all silence, can't that be copyrighted?

But in reality, couldn't one argue that the copyright covers the name '/bin/true' and the empty file contents?

Or that the whole work is copyrighted, with a stamp on each file to remind you of that fact?

</comment><comment><USER14> I think I remember an engineer I worked with in the past gleefully pointing to a preface page in an Intel handbook for a chip Intel designed that Intel had copyrighted the lowercase letter i.

(f recall correctly...)

</comment><comment><USER15> Idea for GNU's /bin/true new option: --false, that would make it exiting with 1.

<comment><USER16> That might be a little too confusing. But --true and --false options would be right at home in a /bin/bool command.

</comment></comment><comment><USER17> "So if you use blank lines in any of your files, you are in blatant violation of AT&T's copyright claim."

WRONG!

</comment><comment><USER18> For fun, if you are running OS X 10.7:

        codesign -d -v /usr/bin/true

<comment><USER19> Aha, that helps explain the discrepancy of OS X 10.7:

        $ ls -la /usr/bin/true /usr/bin/false
        -r-xr-xr-x  1 root  wheel  34240 Jul 20  2011 /usr/bin/false
        -r-xr-xr-x  1 root  wheel  34240 Jul 20  2011 /usr/bin/true
        $ cmp -l /usr/bin/true /usr/bin/false |wc
            8194   24582  114716

and CentOS 6:

        $ ls -la /bin/true /bin/false
        -rwxr-xr-x. 1 root root 25144 Dec  7 14:51 /bin/false
        -rwxr-xr-x. 1 root root 25144 Dec  7 14:51 /bin/true
        $ cmp -l /bin/true /bin/false |wc
            355    1065    4970

The signature size explains (part of) the larger delta on OS X, but left me wondering, so:

        ~/coreutils/src]$ ls -alrth true.c false.c
        -rw-r--r--  1 dvd  staff   2.2K Jan 30 09:31 true.c
        -rw-r--r--  1 dvd  staff    51B Jan 30 09:31 false.c

Curious!

        ~/coreutils/src]$ cat false.c
        #define EXIT_STATUS EXIT_FAILURE
        #include "true.c"

And figuring out why that still results in such a large binary delta is over my head.

<comment><USER20> _And figuring out why that still results in such a large binary delta is over my head._

On OS X these binaries are fat binaries:

        $ file /usr/bin/true
        /usr/bin/true: Mach-O universal binary with 2 architectures
        /usr/bin/true (for architecture x86_64):	Mach-O 64-bit executable x86_64
        /usr/bin/true (for architecture i386):	Mach-O executable i386</comment></comment></comment>


Project Cybersyn, a 1971-73 Chilean Experiment in Computer-Assisted Economy - <AUTHOR> http://www.damninteresting.com/nineteen-seventy-three/ <comment><USER2> "General Augusto Pinochet remained the de facto dictator in Chile until 1988, when he acquiesced to pressure from the citizenry, the UN, and the Catholic church to reform the constitution and hold a new presidential election. The Chilean people declined to re-elect him. He stepped down in 1990 and left the country"

This is inaccurate. Pinochet had a new constitution written and it was passed on the 1980 national referendum (see [http://es.wikipedia.org/wiki/Plebiscito_nacional_de_Chile_de...](http://es.wikipedia.org/wiki/Plebiscito_nacional_de_Chile_de_1980)).

The Chilean constitution of 1980 included a "transitional" amendment stating that, if passed, Pinochet would be president for the next 8 years after which another referendum would be called with the following options: \- Yes: Pinochet would rule for yet another 8 years with the "junta" remaining as the legislature. \- No: Pinochet would stay for 1 year after which a democratically elected president and congress will take over the executive and legislative branches of government.

"NO" won that referendum (I was just old enough to vote NO). So Pinochet, respecting the terms of the Constitution he wrote, called for democratic elections for President and Congress.

Also, Pinochet could not run for the 1989 presidential election because his own constitution prohibited consecutive presidential terms.

One interesting note: Pinochet was so confident he would win the referendum they didn't think they would need a building for Congress. They had to rush design and construction of the Congress building to the point only the main chamber was completed on time for the new president's oath ceremony.

</comment><comment><USER3> The biggest problem every communist country had was indeed coordination. The USSR was famous for this, in fact the Nazi invasion was a success at first partly because of Soviet disarray: you had spies warning about the impending attack for months while factories churned tanks but not supply trucks, and the army trained soldiers but didn't make enough rifles for all of them.

And this happened on a day-to-day basis: you had factories making 10,000 units when only 1,000 were needed, or worse when the demand was of 100,000. Food supply was always a problem and still is in countries like Cuba and NK. I have friends a bit older than me that lived under such conditions and still remember having to wake up at 4AM to grab a nice spot at the store line. "Show up late and there was no food left" they said.

This Chilean system was without a doubt the right solution for the problem, too bad that it was destroyed before it could do what it was meant to do.

<comment><USER4> I don't understand how communism is related to the article. Allende was socialist, not communist. They are different political systems.

<comment><USER5> One of the S's in USSR the 'classic' communist country stood for socialist. Granted the Communist party in the Union of Soviet Socialist Republics is probably what really confused most people.

<comment><USER4> Then I guess 7 = 11 because the store 711 puts the together...

<http://en.wikipedia.org/wiki/Communist> <http://en.wikipedia.org/wiki/Socialism>

They can put whatever they want in their name, and even mix and match the terms in their propaganda... reality remains that they are different political doctrines.

</comment></comment></comment></comment><comment><USER6> Related reading:

<http://en.wikipedia.org/wiki/Economic_calculation_problem>

<comment><USER7> OP's article reminds me of Molineux's critique of the Venus Project: "Marxism with robots"

</comment></comment><comment><USER8> Here is a short presentation with another perspective on the Cybersyn project which should be of interest to designers and quantitative visualization types: <http://compscifi.com/>

It argues that the design of the Presidential control room and its simplified visualizations of economic information created an illusion of omniscience and control over the economy by using visual cues from modernist design and science fiction. But behind the scenes, the project was mostly run by humans exchanging data over teletype machines and hand-pasting information to slides.

There's a wonderful example of the project's simplified model of the economy around 7:58. Do you think this captures the complexity of the Chilean economy with enough fidelity that policymakers could have made reliable predictions about the effects of their interventions? (I don't. This is why: <http://www.econlib.org/library/Essays/hykKnw1.html>)

I have great hope that agent-based modeling and simulation will become useful tools in economics, but they are only useful when we accept that they are wrong. We should approach synoptic tools like Cybersyn that promise power and control over complex social systems with extreme skepticism.

</comment><comment><USER9> I found this: <http://code.google.com/p/albastryde/>

ALBAstryde takes its name in part from the Bolivarian Alternative for the Americas (ALBA). The second part of the name is linked to its historic root, Cyberstryde, which was the software behind Cybersyn, the cybernetic network which was set up under Salvador Allende in Chile 1971-73 to make information about industrial production instantly available to workers and government. ALBAstryde is being developed to be first used as a base for the software of the Ministry of Agriculture and Forestry of Nicaragua.

<comment><USER10> I collaborated in this one, more information here: [http://www.linuxjournal.com/content/nicaragua-builds- innovat...](http://www.linuxjournal.com/content/nicaragua-builds-innovative- agricultural-information-system-using-open-source-software)

<comment><USER11> how did it turn out? was it used / reused / spur on something else? what lessons can be learned from what happened? (thanks).

<comment><USER10> I just checked and they have no data for this year sadly :-( but they did used it for 2 years, I don't work for the ministry but I did worked for the NGO that made it so I don't know how well did they use it.

</comment></comment></comment></comment><comment><USER12> i'm Chilean and this is a huge problem here in Chile. Allende's government is constantly remembered as "what is what could have happened if US had not intervened?"

<comment><USER13> Even so I usually get shunned by that opinion, I honestly believe that Chile is one of the examples where American interventionism has worked. Sure, there are a lot of question marks about the methods, but the long time effects are astonishing.

This is even more amazing taking into consideration its geographical location and the situation of its neighboring countries. Friedman should get another Noble Prize just for being one of the few economists, who were given this fascinating opportunity of putting his economic views at work - and providing evidence that it does.

Something like Startup Chile gives me hope that this spirit of unconventionalism stays relevant even today.

<comment><USER14> I'm sorry... are you actually saying that the intervention in Chile "worked"? What do you actually mean by "worked"? If you mean "they fixed the economy only after screwing it up themselves" then that's called "cleaning your own mess" and not fixing something. Sure, it wasn't the best thing and Allende's government had many faults, but it wasn't the big mess they try paint it.

Being a chilean, I would say that the chilean economy and the whole system is in a very bad shape: huge inequalities, screwed up health system, educational system about to collapse, etc... Most of them we can thank Friedman and his free market policies... so don't tell me that the intervention in Chile was a good thing or turn out to be a good example, there are many, many counter- examples you can find of how bad things are now because of the intervention and forced policies in the economy.

<comment><USER13> This is what I mean by worked:

 _It leads Latin American nations in human development, competitiveness, income per capita, globalization, economic freedom, and low perception of corruption. It also ranks high regionally in sustainability of the state, democratic development and state of peace. However, it has a high economic inequality, as measured by the Gini index._

<http://en.wikipedia.org/wiki/Chile>

<comment><USER14> That doesn't mean at all that it worked. All that information means is that Chile, _now_ is in a good position _relative to the rest of Latin America_. Taking conclusions and saying that the reason Chile is the way it is now is due to the US intervention is naive and simplistic. There are so many factors involved in that fact, that it makes little sense to make that argument.

Using the same co-relation you're trying to use, I could say that the intervention was a bad thing, because while Chile is not bad, we could be doing a lot better if it weren't because of the problems we had to face. That is also not the case, and again, too many variables involved that you're freely taking away.

<comment><USER13> I absolutely agree that certain key numbers are always simplifying the complexity inherent in an economy. But it appears to the outside, that fundamentally there are no particular reasons that would make Chile any different to other Latin American countries (e.g. historic trade positions, natural resources, etc).

<comment><USER15> You don't know what you're talking about.

<comment><USER16> You seem biased. He offered a valid argument.

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER11> there's a related book come out recently - <http://redplenty.com/Front_page.html> \- that looks very interesting. the author, francis spufford, seems like a very smart guy (he recently wrote a very good (imho, as an atheist) article on being a christian, related to his latest book - see [http://www.guardian.co.uk/books/2012/aug/31/trouble-with- ath...](http://www.guardian.co.uk/books/2012/aug/31/trouble-with-athiests- defence-of-faith))

[but i think this has been posted and discussed here before]

<comment><USER17> _Red Plenty_ was great, although it's not quite what I had expected. Anyway, anyone even remotely interested in central planning must read Cosma Shalizi's [http://crookedtimber.org/2012/05/30/in-soviet-union- optimiza...](http://crookedtimber.org/2012/05/30/in-soviet-union-optimization- problem-solves-you/)

(I'd say that's much more interesting than the Chile stuff, but that's just me.)

<comment><USER11> that's great, thanks (i think i found out about red plenty from crookedtimber, but i had never seen that post). do you know of any other books that are vaguely connected? i once read "machine dreams" [http://www.amazon.com/Machine-Dreams-Economics-Becomes- Scien...](http://www.amazon.com/Machine-Dreams-Economics-Becomes- Science/dp/0521775264) and enjoyed it hugely, but have never found anything even remotely similar.

</comment></comment></comment><comment><USER18> In the last couple of years I've been reading the books of Stafford Beer, and he had some interesting ideas which were way ahead of his time. It's debatable how well Cybersyn and Cyberfolk would have worked in the early 1970s, using a single IBM computer plus telex systems. Today we would call this type of system SCADA, but Beer's ideas extended beyond factory control into the overall economy and political process.

At the time Cybersyn was portrayed in the British and some of the Chilean newspapers as a totalitarian "big brother" system, but that wasn't how it was designed to work. Beer saw the economy as a closed loop rather than a top down hierarchy, and he knew about and was hostile towards the Soviet GOSPLAN type economy.

If you're interested in Cybersyn then there is a recent book by Eden Medina called "Cybernetic revolutionaries" which describes the system and its development.

</comment><comment><USER19> Stafford Beer, the architect and excellent storyteller, presenting the cybernetic paradigm: [http://www.youtube.com/watch?v=7O09FPHuCQQ&feature=youtu...](http://www.youtube.com/watch?v=7O09FPHuCQQ&feature=youtu.be)

Also, a quick explanation of the viable system model: [http://www.youtube.com/watch?v=jpX7T_sZWMc&feature=youtu...](http://www.youtube.com/watch?v=jpX7T_sZWMc&feature=youtu.be)

</comment><comment><USER4> I am Chilean and there is a minor correction to the article:

"He attempted to phone the general of the Air Force and the new commander-in- chief General Pinochet, but they declined to answer" Pinochet was not the commander in chief of the Air Force, but of the military. The Air force was part of the Junta, and as such supported their leader Pinochet.

Otherwise excellent article.

<comment><USER11> it's poorly written, but because it says " _they_ declined to answer" it's likely that the author means "the general of the Air Force and the new commander-in-chief General Pinochet" to be a list of two people.

(but still, your english is better than my shameful spanish, and i have lived in chile for many years...)

<comment><USER4> I stand corrected

</comment></comment></comment><comment><USER20> Are there any technical details available of how the system functioned? And has anything similar been attempted since?

<comment><USER21> Not well. It was essentially run manually, with humans stitching together telexes and slide projections.

There's an interesting video here. <http://vimeo.com/8000921>

</comment></comment><comment><USER22> As an aside, I can recommend the alternate history novel Synco, from author Jorge Baradit, based on the Cybersyn project. <http://www.amazon.com/Synco- Jorge-Baradit/dp/9563040562>

</comment><comment><USER23> I have been obsessed with this ever since I read an article in the guardian (uk) circa 2003 of all places. If you want a better picture of the political situation check out "a promise to the dead" (by ariel dorfman <http://www.imdb.com/title/tt1097260/>).

You can also read designing freedom (written right after the coupe) to get a solid idea of what stafford beer was driving at [http://ada.evergreen.edu/~arunc/texts/cybernetics/beer/book....](http://ada.evergreen.edu/~arunc/texts/cybernetics/beer/book.pdf)

</comment><comment><USER24> This was really a fascinating read.

</comment><comment><USER25> Sometime i hate being in the backyard of EEUU</comment>


Writing ReasonML Bindings for JavaScript APIs - <AUTHOR> http://davidgom.es/2017/12/23/reasonml-webworkers-bindings.html <comment><USER2> The problem I see with the bindings at the moment is, JS uses very different data structures from Reason, so a simple conversion often doesn't give you the power pf Reasons type system.

This requires people to bind to JS and then do some runtime-conversion to get idiomatic Reason out of it.

<comment><USER3> Not really. You can model complex js data type as abstract type, and only provide functions needed

<comment><USER2> JS data structures are basically big objects with strings as differntiator. Reason works with lists, tupels and variants

<comment><USER4> And records. You would typically define a record type to do the heavy lifting in, and do some lightweight conversions to and from JS. Here's an example:

        [@bs.deriving jsConverter]
        type person = {name: string, age: int};

        let bob = {name: "Bob", age: 33};
        let olderBob = {...bob, age: bob.age + 1};
        let () = Js.log(personToJs(olderBob));

<comment><USER2> But the records wouldn't use variants.

<comment><USER4> Nope, you can definitely use variants in the records. BuckleScript (the compiler) will automatically convert them into JavaScript-friendly representations. Or you can also pick custom representations for each variant case.

<comment><USER2> Ah, yes if you only go from Reason to JS, becaue Reason is much richer.

I was thinking about going from a JS library to Reason, where you basically get bags full of strings.</comment></comment></comment></comment></comment></comment></comment>


Ask HN: Why newer TV sets have analog power switch? - <AUTHOR>

My older television set would auto off when power goes down so it wouldn't start back automatically if power comes back, makes sense. But the modern TVs wouldn't they would turn on as soon as power comes back, you have to explicitly press that power button. I just couldn't get why there is this change in design? <comment><USER2> I'm not sure how old your television was, but I haven't seen a physical power switch on a TV since the 1980's. Newer models have an electronic power button so that you can turn it on manually or with the remote. If there were a physical power switch on a modern TV, switching it off would render the remote useless until you walked over to the TV to turn it on.</comment>


Slack Acquires Spaces - <AUTHOR> http://blogs.wsj.com/digits/2014/09/26/slack-buys-a-collaboration-tool-in-first-acquisition/

<comment><USER2> Great news for Spaces ([http://spaces.pm/](http://spaces.pm/)), but am I the only one who prefers HipChat over Slack? Due to its feature set, Slack gets way too noisy thus unproductive.</comment>


PG at Defcon 13 (2005) - <AUTHOR> http://www.youtube.com/watch?v=v8Lb8ZgQP74

<comment><USER2> pg is a lot more charismatic and without the 'uhhs' and 'uhms' in his speech here. I wonder if it's because the defcon crowd is more playful than, for example, the Python crowd he gave a speech to a few months ago.

Granted he's just reading it off a sheet of paper -- but, he's still presenting in a pretty engaging and fun way.</comment>


Android Developer Report: Breaking Even in 21 Days - <AUTHOR> http://trollaroid.com/blog/21_days_on_the_android_market/

<comment><AUTHOR> 21 days, 32 dollars isn't the best hourly wage. From a first-time app developer to anyone with experience, how do you think I could get things going from here?</comment>


Ask HN: How to build a test harness for a legacy system? - <AUTHOR> I'm working with a legacy system that has no automated testing. I have a section of code that I need to refactor or it is going to get increasing more coupled. First, I tried going through the Legacy Code Change Algorithm but when trying to break dependencies, I'm moving a lot of code around (maybe I'm doing it wrong?).
I'm starting to think now that it would be a good idea to build automated acceptance tests around the functionality that I want to refactor, before breaking dependencies. Should I revisit how I am breaking dependencies or would it be worthwhile to take this path?
Any other words of wisdom you can impart my way? <comment><USER3> If it's got a web interface I suggest starting with browser-based testing like Selenium. It won't be as good as unit tests but will catch the obvious fuckups. I plan on doing this to a legacy project at my employer's and I already know it would've caught a few production fuckups we had lately - <USER2> error on the homepage, etc.

This also means you don't even need to be familiar with the code base, but just know how to use the web interface as a normal user would.</comment>


How Much Does It Cost to Clone Your Favorite App? - <AUTHOR> http://priceonomics.com/how-much-does-it-cost-to-clone-your-favorite-app/

<comment><USER2> Another app & site pricing resource also from a designer/developer-for-hire service is [http://howmuchtomakeanapp.com/](http://howmuchtomakeanapp.com/) Upon cursory use their estimates seem to be much higher than Gigster's, which could be a valuable thing to show potential clients come quoting time.</comment>


TheFunded Founder Gives Startups Some Advice - <AUTHOR> http://www.techcrunch.com/2008/04/03/thefunded-founder-gives-startups-some-advice/ <comment><USER2> What do you guys think about VCs sharing your information with others?

Necessary? Unethical?

I lean to the latter.

<comment><USER3> Fact of life?

Plied with alcohol, I could provide multiple anecdotes about VCs taking meetings solely to funnel competitive intel to portfolio companies; I did a pitch meeting once where a senior partner for a top tier VC literally ambushed us with a competitor in the room.

</comment></comment><comment><AUTHOR> More here:

<http://thenextweb.org/2008/04/03/keynote-adeo-ressi/>

</comment><comment><USER4> probably good advice, I wish I could only do business with friends that are trust worthy but they aren't rich. This "real world advice"

</comment><comment><USER5> pg or any of the YC founders want to comment?</comment>


[Show HN] GnuBackgammon port for Android - <AUTHOR> https://github.com/alcacoop/it.alcacoop.gnubackgammon

<comment><AUTHOR> We @ Alca Società Cooperativa (<http://alcacoop.it>) are proud to announce the release of GnuBackgammon Mobile for Android as well as its source code: GnuBackgammon Mobile and libgnubg-android.

libgnubg-android is a real port of GnuBackgammon (gnubg) AI (<http://gnubg.org/>) and, among the others, one reason of this port is also the chance to reintegrate our work into the gnubg source tree in order to create a real linkable library (as it happened for GNU Chess, as an example). Actually it compiles on x86 and ARM (v6/v7).

GnuBackgammon Mobile is released under a GPLv3 license, you can find source code on GitHub at: <http://github.com/alcacoop/it.alcacoop.gnubackgammon> <http://github.com/alcacoop/libgnubg-android>

A precompiled version of GnuBackgammon Mobile is available on Google Play Store at [https://play.google.com/store/apps/details?id=it.alcacoop.gn...](https://play.google.com/store/apps/details?id=it.alcacoop.gnubackgammon)

Our future goals are: * extracting analysis and rollouts tools from gnubg * introducing real multi-threading * porting of SSE2 code to SIMD (neural net implementation).

If anyone would like to contribute, please fork us on GitHub or write at email@example.com</comment>


The Optimal Blog Post Length to Maximize Viewership - <AUTHOR> http://tomtunguz.com/content-marketing-optimization <comment><USER2> I don't understand how any of this is useful.

\- he samples only his own writing

\- he has a far bigger sample of "medium-length" articles (how big are his samples of 100 word posts? 2000 word posts?)

\- the title seems intentionally misleading, making it seem like it was actually a scientific analysis, and that a positive result was actually found

\- content isn't controlled for. How are retweets a useful metric for measuring optimum length? Wouldn't that have far more to do with content?

\- doesn't take into account the presentation of information

\- doesn't take into account his audience

\- etc, etc.</comment>


The Unix Time-Sharing System, unpublished draft (1971) [pdf] - <AUTHOR> http://ftp.math.utah.edu/pub/mirrors/minnie.tuhs.org/PDP-11/Distributions/research/McIlroy_v0/UnixEditionZero-OCR.pdf <comment><USER2> This needs more visibility. It appears to be a previously unseen document in UNIX's history (at least judging by it appearing couple of days ago on the TUHS site, and not a couple of decades).</comment>


How Not To Get Noticed: Design and Usability lessons from WordPress - <AUTHOR> http://www.slideshare.net/edanzico/how-not-to-get-noticed <comment><USER2> Didn't seem that useful to me. Some slides were incomprehensible (no. 17 ?!?)</comment>


Ask HN: Does anyone have ideas for an independent study? - <AUTHOR>

I've decided to take an independent study this semester, and I'm looking for something research worthy that I can conceivably build in a semester. The professor I've teamed up with focuses on pedagogy and reliable systems, so I'd prefer to do something in those areas.
I've previously tried to set up classes in the high school I graduated from to teach interested students how to program/build websites/etc., but it seems my old high school is uninterested in educating their students for free (go figure). I suppose with connections in the university, I could probably do this more easily, so I haven't ruled out trying to figure out how to get high school students interesting in CS. I have a particular draw to this because if it were not for a particularly good teacher in high school, I would've never discovered my passion for CS.
I'm a web developer by day, so doing something with the web is also of interest to me. One idea I had kicking around was to build an automatic failover to EC2 for sites not hosted on EC2.
If anyone has any other ideas or suggestions, I would greatly appreciate it. <comment><USER2> Why not design an information system for individual/small group tutoring scheduling, that collects small groups of students having trouble with some subject and matches them with someone interested in tutoring them? This could work for both high school interest groups (that needn't be bound to the classes already defined by the school) and university (especially first-year students getting up to speed).</comment>


Druid Enables Analytics at Airbnb - <AUTHOR> https://medium.com/airbnb-engineering/druid-airbnb-data-platform-601c312f2a4c <comment><USER2> There's a similar story of using Druid at Netflix: [https://news.ycombinator.com/item?id=22574647](https://news.ycombinator.com/item?id=22574647)

Druid is a very specialized datastore with a niche usage around low-latency analytics under specific pre-set aggregations but it has a lot of moving parts. It also just recently got a beta SQL interface (which translates to the underlying custom JSON API) and isn't as easy to integrate with existing tools (outside of Kafka).

Overall I suggest smaller companies stick to a standard column-oriented data warehouse like Redshift, BigQuery, Snowflake, Clickhouse, MemSQL, etc instead of Druid.</comment>


Ask HN: Can Freedom Exist Online? - <AUTHOR> If governments can monitor all internet traffic, can humanity be free online? I finished watching Citizen 4 and I was wondering if anything had changed since 2013. <comment><USER2> I don't think so, I think surveillance and freedom are mutually exclusive in most spaces and most applications.</comment>


Would it be cool to be able to search a video? - <AUTHOR>

I'm currently trying to find a segment in a video that is about 56 minutes long. <comment><USER2> Yes, that would be cool. I am curious as to how such a search would be performed by the user. Perhaps entering a duration in minutes and seconds and using arrow keys to shift the buffer bar location left/right until the correct scene is found, or searching for known dialog text and mapping transcript to location in the video that that specific part of the transcript was said in dialog might be a useful addition to the already-available "thumbnail search" most video players provide today (when you hover over the loading bar, a thumbnail image of that scene appears in a tooltip).

Something useful I've seen in very few places are video players that maintain a history of the duration of the video that was watched, so if the internet ever cuts out or the video stops loading the page could just be reloaded and the duration in the video will be maintained, albeit 1 minute prior just as a quick recap of what happened. When this feature is not available, and the connection is shoddy, watching videos can be very frustrating because having to find where you were previously can sometimes take ages, especially if the loading bar has no indication of what duration in minutes the video is at the location you hover your mouse on the loading bar.

What else other than this could add any real value to the act of searching a video? Perhaps mapping words to visual cues, for example searching "helicopter explosion" would take you directly to an overdramatic scene of a helicopter being blown up in magnificent ember by a missile that is clearly too small to do much damage to a bicycle let alone a helicopter, that would be cool.

<comment><AUTHOR> You bring up some interesting concepts on how to "search a video". Great ideas. My initial thought was to have segments tagged, with phrases / keywords.</comment></comment>