Meerkat Learns Buzz Doesn't Always Mean Business - <AUTHOR> http://www.bloomberg.com/news/articles/2015-04-15/meerkat-learns-buzz-doesn-t-always-mean-business

<comment><USER2> I am still absolutely struggling to see a popular use case for these applications. I would be interested to read about how those who financed/invested in these products, Meerkat in particular, came to the conclusion that it was worth a punt.

The only time I heard Meerkat being mentioned was in the context of Periscope stepping into its place at launch time. The only time I've heard about Periscope being used since its launch was in reading about HBO shutting down those streaming GoT on it.

"If you build it, they will come" seems to have been morphed into "If you build it, hopefully they'll find a reason to use it" here.

<comment><USER3> The easiest way to get attention from the media is by creating something that the media is interested in. Internet media types love the idea of citizen journalists submitting live video from breaking events, so it's an appealing angle for them to write about. The story (what Meerkat could do) is a lot more exciting than the current reality (how many people are _actually_ using Meerkat).

<comment><USER4> Like Twitter, it's a not-especially-good idea that's one major celebrity thinking it's cool or a couple of major livestreamed incidents away from being potentially pretty big. Integration with existing social networks is going to be the key bit for regular users though, as the average person wants to passively showcase the cool thing they're doing to their friends rather than random members of the public.

It's not a hugely novel idea though; a couple of days ago we had an article on the first girl to lifestream her life, in _1996_.

</comment></comment></comment><comment><USER5> When are we going to learn? Ripping some tech PR and being at SXSW getting PMF with techies and media-types for a product that needs mainstream traction is a death-knell.

The same happened with Secret/Whisper last year and I commented that based on my focus groups in the Midwest, Yik Yak was going to clean their clock. And they did.

It's because mobile is so pervasive and mainstream we need to look at the market from a mature distribution perspective. Dare I say even from a packaged goods perspective. How do you get a new brand of yogurt on the shelves? What's the quality bar necessary? If you win at distribution where everyone lives, you win period.

The "Crossing the Chasm" Christensen model that worked for Google over a decade ago when the preferred medium of distribution of a tech product was not mainstream does not apply today for consumer.

</comment><comment><USER6> The live-streaming market is still young. I doubt Meerkat's investors are expecting profits or a viable business model any time soon (this seems like the classic "build a user base and figure out the rest later" model). While buzz may not mean business, it definitely creates opportunity.

</comment><comment><USER7> Actually it does..it's just not sustainable under its current incarnation. The buzz factor is real and meerkat team have earned brand equity that can be used for countless other projects for years to come.

<comment><USER8> "Brand equity" doesn't work if people forget your startup within _weeks_.

</comment></comment><comment><USER9> Easy come, easy go.</comment>


Microsoft Is Interested in Buying Stake in Dailymotion - <AUTHOR> http://techcrunch.com/2014/02/25/microsoft-is-interested-in-buying-stake-in-dailymotion/ <comment><USER2> Kind of a misleading title, Microsoft is interested, it hasn't been approved at all.

> In April 2013, Yahoo was about to acquire 75 percent of Dailymotion for $200 > million. Yet, the French government suspended the deal as the state still > owns 27 percent of Orange. "Montebourg didn't want to let it go to the > Americans," a source told TechCrunch at the time — Arnaud Montebourg is the > French Minister of Industrial Renewal.

Who knows, the same thing could happen this time.

Looks like Microsoft is looking for it's own YouTube.

<comment><USER3> Government didn't want to sell, but the current talk with Microsoft is explicitly about Orange keeping majority ownership but finding an international partner.

Source in french: [http://www.lemonde.fr/technologies/article/2014/02/25/orange...](http://www.lemonde.fr/technologies/article/2014/02/25/orange- confirme-discuter-avec-microsoft-d-une-cession-partielle-de- dailymotion_4372864_651865.html)

</comment></comment><comment><USER4> _> "Dailymotion is one of France's biggest Internet successes"_

That tells a lot about France's so called "successes" (I'm French btw)

<comment><USER5> Maybe because the french encourage healthy competition [1] rather than US- style 'free-market' monopolies like Google, Microsoft, Amazon, Comcast...

[1] [http://www.nytimes.com/2013/10/04/business/France-Takes- Aim-...](http://www.nytimes.com/2013/10/04/business/France-Takes-Aim-at- Amazon-to-Protect-Local-Bookshops.html?_r=0)

<comment><USER6> From the first line:

>French lawmakers on Thursday took aim at Amazon to protect local bookshops by voting through a law that bars online booksellers from offering free delivery to customers on top of a maximum 5 percent discount on books.

Now as I understand it, competition is supposed to help the consumer, and the French government essentially did something anti-consumer. I understand your need to go on your "anti-US" soapbox, but your post is outrageous. In what was is Google a monopoly? Last I checked Bing had a 20% marketshare.

<comment><USER7> Besides, Google won the search market due to a _massively_ superior product. The race wasn't even remotely close, they demolished the competition with an easier, faster, better offering in every possible respect. What alternative is thisiswrong proposing one wonders: that the government should have forced dramatically inferior products on consumers at gun point? Quotas on how often consumers can use Google? It'd be laughable if it weren't such a dark perspective.

</comment></comment></comment></comment><comment><USER8> The title here is misleading they are looking for Minority partners for investment for international growth.

It would be an interesting position for Microsoft to take particularly as they seem to be going all in on mobile.

As an aside I prefer dailymotion in just about every way to youtube so I hope they do well.

</comment><comment><USER9> Is Microsoft on a mission from NSA to buy all European companies, or something? Skype, Nokia, Dailymotion...

<comment><USER10> Microsoft (like Apple, Google, etc) has a large portion of their profits stuck overseas and can't repatriate that money without paying US income taxes on it. That's why spending the money internationally is appealing to them.

<comment><USER11> Does it mean that they can't pay dividends using their oversea money?

<comment><USER10> I only understand the broad strokes well enough to say for certain. My assumption is that they can do anything they want with the "Double Irish" money, but they avoid bringing it back into the US if at all possible since they'd have to pay corporate income tax on it at that point.

</comment></comment></comment></comment><comment><USER12> Id be interested in seeing statistics on how many Dailymotion uploads are adult content vs higher value non-adult content. The only time I see Dailymotion links are for videos containing ripped adult scenes from TV/Movies..

</comment><comment><USER13> These positions by countries that like to reduce foreign ownership of non- critical businesses strike me as bizarre. It radically reduces the market value of the business, and thus greatly reduces their ability to raise money and grow organically.

No coincidence such markets tend to have a reputation as being nightmares to attempt to grow in.

<comment><USER14> It usually prevents the business' core from going away (if Microsoft moves the headquarter to London or Seattle for instance). The point would be less to preserve market value than jobs, technical expertise and surrounding ecosystem.

Not that I strongly agree with this line of thinking, I'm unopiniated at best.

</comment></comment><comment><USER15> The title here is completely wrong. The article mentions that they are potentially in talks to buy a stake in DailyMotion, but nowhere does it state that MSFT will be buying them for certain.

<comment><USER16> I think that is what "interested" means.

</comment></comment><comment><USER17> After the debacle around Yahoo buying a majority share I'm somewhat surprised that Microsoft would still be interested.

</comment><comment><USER18> And possibly thinking of having their own 'YouTube'?</comment>


Going to China to make the perfect tee - <AUTHOR> http://blog.theopencompany.net/post/29079747110/going-to-china-to-make-the-perfect-tee

<comment><USER2> I was disappointed to find out this wasn't about a revolutionary golf tee design.</comment>


Android's Final Challenge Winners  - <AUTHOR> http://code.google.com/android/adc_gallery/index.html#1

<comment><USER2> My favorite of these is "GoCart". I want an Android phone just for this:

"GoCart is your shopping cart on-the-go. Users can scan the barcode of any product using their phone's built-in camera. Once scanned, it will search for all the best prices on the internet and through the inventories of nearby, local stores."

<comment><USER3> How do they get the inventory of nearby, local stores?

<comment><USER4> I guess one way would be to require the user to type in the price of the object they're reviewing, to seed the database... although that would only work well for a community with a lot of Android cell phones.

Now that I think about it, a database telling which products local people are comparing would be pretty valuable to local stores... They might be willing to trade pricing data for search data? Or a "featured" listing position?

<comment><USER5> GoCart gets the local prices from the website itself. Several merchants' websites have a "check local inventory" feature where you supply the zip code to get a list of stores. Check out the video at <http://www.biggu.com>

</comment></comment></comment></comment><comment><USER6> I'm glad to see The Weather Channel didn't receive any money even though they were a finalist. I don't think they need it as much as a small developer bootstrapping their app.

<comment><USER7> I'd hope that Google, of all companies, is better than that. "You do better work, but we're looking for someone a little more pathetic" is not going to get them anywhere.

<comment><USER8> I'm guessing that it would be more a factor of 'bang for your buck'. That money is going to go a lot farther at a startup than at a company worth billions of dollars:

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

Plus, a weather app is kind of obvious, even if well done.

</comment></comment></comment><comment><USER9> Some clever ideas in there which shouldn't be too hard to port to iPhone.

1\. Port ADC winning entries to iPhone

2\. ???? (sell on AppStore)

3\. Profit!

The share your whiteboard app looks especially cool.

<http://code.google.com/android/adc_gallery/app.html?id=39>

</comment><comment><USER10> What, that Augmented Reality/Google Maps mashup didn't make it? That was 10x more impressive than any app there!

<comment><USER11> You talking about enkin?

I read that they are apparently working for Google now.

[http://androidguys.com/2008/08/26/googles-not-so-secret- stra...](http://androidguys.com/2008/08/26/googles-not-so-secret-strategy/)

<comment><USER12> So the _real_ winner(s) got bought by Google...

</comment></comment></comment><comment><USER13> <http://twitter.com/sacca/statuses/897820817>

A lot of these would make great web apps/sites too.</comment>


Ad-blocker counter-detection: State of the art and new approaches (2017) [pdf] - <AUTHOR> https://bitbucket.org/joanbrugueram/content-filter-policy/downloads/initialrelease-thesis.pdf <comment><AUTHOR> This was my undergraduate thesis. In short, apart from the long sections where I explain the state of online ad-blocker detection, I built a prototype that can avoid ad-blocker detectors by temporally unhiding the advertisments when a script from the website queries the DOM for information about them. Basically, you can also look at it as having a "user DOM" that has the advertisments hidden and a "website scripts DOM" that has the advertisments visible. I did this by doing script rewriting through a MITM proxy and JavaScript function overwriting (hooray prototypes!).

There are some rough edges to this work: Both in form (English is not my first language, and I was working full time while developing it so it is nowhere as polished as it should be) and in content (the 'undetectable' ad-blocker prototype is very basic, and there are some worrying doubts about real-world feasibility in regards to performance and privacy). I also haven't been able to continue developing this project further because of real life constraints.

Additionally, a [very innovative paper]([http://randomwalker.info/publications/ad-blocking- framework-...](http://randomwalker.info/publications/ad-blocking-framework- techniques.pdf)) on this area came out while I was working on it, which simultaneously made some of my stuff redundant, but also complimented my work very well.

You can also see my presentation [here]([https://bitbucket.org/joanbrugueram/content-filter- policy/do...](https://bitbucket.org/joanbrugueram/content-filter- policy/downloads/initialrelease-presentation.pdf)) for a quick and very rough summary.</comment>


Key ideas of linear algebra [pdf] - <AUTHOR> http://web.mit.edu/18.06/www/Essays/starting2matrices.pdf

<comment><USER2> FYI, Strang's textbook is commonly used in linear algebra courses.</comment>


Choosing your cloud (a quick primer) - <AUTHOR> http://blog.labslice.com/2010/10/choosing-your-cloud.html A quick primer to highlight the difference between the big cloud vendors -- Amazon, Google and Microsoft. <comment><USER2> No mention of Rackspace, Linode, or Slicehost? How about any of the bevy of newer "cloud" providers?</comment>


Ask HN: Rate my Startup - <AUTHOR>

Cooleaf-Live Healthy, Be Rewarded
Please watch our video demo at this link and provide me with your feedback via our survey questions:
http://www.surveygizmo.com/s3/390709/Cooleaf-survey
thanks! <comment><USER2> Where's the site? I don't see a startup, I see an idea.

<comment><AUTHOR> Application is currently in development for launch Q1 next yr

<comment><USER2> Well I didn't watch the video I'm afraid - 2 minutes is a long time to watch a demo. Perhaps you could get some feedback by paying people on Amazon's mechanical turk.</comment></comment></comment>


DocuColor Tracking Dot Decoding Guide - <AUTHOR> https://w2.eff.org/Privacy/printers/docucolor/ <comment><USER2> How is a printer able to print those dots on so many pages? At some point, this special yellow ink must become depleted, right?

Or does it use the regular ink which is provided by the printer's cartridge? If this is the case, isn't a possible defense to just not buy new color cartridges? At least for me, I have to print colored documents at most every 3 months. Unfortunately the color cartridges dries out after about 6 months which means I would have to pay $20 to print less then 10 pages. Thus, I only buy the black ones and when I have to print something in color, I just put it on a USB stick and print it at work (I am allowed to do that in moderate amounts) or go to a shop with printing services and pay $1 for those documents.

Since my color cartridges are almost two years old (and still full according to my printer), though I cannot print a single page, am I still "affected" by those tracking dots?

<comment><USER3> You should probably just buy a black and white laser printer. They're not much more expensive than inkjets anymore, have excellent Linux support, and you get hundreds of pages per cartridge.

Anecdotally mine occasionally adds garbage to the page, I don't know if this is for tracking or if it's just an artifact of the process, but I haven't really been able to trust a printer for years.

</comment></comment><comment><USER4> Thanks you, EFF for giving us useful information about how the government and colluding corporations wish to track us.

</comment><comment><USER5> I wonder if these are uniformly offset from the printed image, and if so, whether printers incorporate any protection to prevent the user from printing yellow dots near enough to them to mask the signature. (If so, it should be easy to make an extension to add such confounding dots to all printed material…)</comment>


Decades-old scientific paper may hold clues to dark matter - <AUTHOR> http://news.sciencemag.org/physics/2014/10/decades-old-scientific-paper-may-hold-clues-dark-matter <comment><USER2> > If they exist, WIMPs would have a mass between one and 1000 times that of a > proton. They would interact only through the feeble weak nuclear force

 _And gravity_. The article even mentions this earlier, but seems to have forgotten about it by the second paragraph. Honestly, I think that a lot of dark matter's popular science reputation as misguided and made up is that articles like this seem so eager to ignore the relatively large amount of information we have about its gravitational behaviour.

(Not that it is necessarily WIMPs, but I think people would be a lot less eager to dismiss this explanation as 'aether-like' if they had a better idea of why WIMPs are proposed in the first place)

<comment><USER3> So this is what I don't understand: there is supposedly 5x as much dark matter as matter. With that much of it floating around, how is it possible that we ever convinced ourselves that general relativity is true? Dark matter is supposedly embedded inside galaxies to the point where stars within those galaxies move faster than they otherwise would. Well, shouldn't the same be true of _our_ galaxy? In fact, shouldn't it be true of our solar system? I just don't see how it's possible that we ever collected data in support of GR only to be surprised later by an anomaly nearly an order of magnitude bigger than the base data. If someone who understands cosmology could please explain this to me I would be most grateful.

<comment><USER4> Space is largely empty; this is a crucial point I will come back to.

Assume a spherical distribution of (dark) matter, with density small enough that we can ignore relativistic effects (which is almost always the case). If you are inside the spherical distribution at a distance R from the center of that distribution, the only effect you will feel is that of the mass inside a sphere of radius R, centered on that distribution. (This is well known for any inverse square law; I can explain more if required.)

The _average_ density of normal/dark matter is very, very small. Inside our solar system, the dominant gravitational effect is that of the Sun: any dark matter having the expected density (from other measurements) would contribute only a tiny amount, so as to be essentially undetectable.

On much, much larger scales, such as the scale of galaxies, far enough from the center (and assuming the dark matter is essentially a spherical distribution coinciding with the galaxy), the cumulative amount of the additional gravitational pull is enough to be detected. Remember that the distance to the nearest stars is _huge_. Yet, our Sun is within a galaxy. So, as I wrote above, the _average_ density of normal/dark matter is very, very small. However, over such large distances as those of the size of galaxies, the cumulative effects can be observed. However, distances involved within our solar system are such that no additional pull from dark matter (comparing the motion of say Mercury to that of Jupiter) is expected to have a visible effect.

<comment><USER5> is it possible that dark matter is regular matter, just so diffuse that we don't notice/see it? could it be hydrogen atoms just floating in empty space, at such low densities we would never notice but in the grand scheme of things add up? Edit: I dont mean to propose a potential solution here, it was more a question of why it must be unknown matter, why can't it be normal matter.

<comment><USER4> No, it is not possible. Cosmological models are actually tightly constrained by data. Even in the late 80s, when we did not have such good data, I remember being amazed at the fact that primordial nucleosynthesis calculations together with observational data were enough to conclude that the number of light "normal" neutrino species was 3, while there were still speculations in Particle Physics that we could have more than 3 generations of particles. The data accumulated over the last 30 years has constrained things even more.

If some other explanation than invoking some new type of matter that can not be seen was possible to explain the observational data, don't you think that Physicists would use that instead of coming up with postulating that the Universe is dominated by "dark matter" and "dark energy" which we have not seen yet?

<comment><USER5> Looking back at what I wrote I can understand your reaction - im wasnt trying to propose a new solution that someone hadn't considered. It was more a question of why couldn't it be that, which you answered quite well, thank you.</comment></comment></comment></comment></comment></comment>


Startup Quote: Alan Kay, computer scientist - <AUTHOR> http://startupquote.com/post/5626579141

<comment><AUTHOR> Simple things should be simple, complex things should be possible.

\- Alan Kay

<http://startupquote.com/post/5626579141></comment>


Your Instagram feed is about to be invaded by more ads - <AUTHOR> http://www.theguardian.com/technology/2015/jun/03/instagram-ads-adverts-facebook-photos <comment><USER2> Please stop spamming submissions. See [https://news.ycombinator.com/newsguidelines.html](https://news.ycombinator.com/newsguidelines.html):

> Please don't submit so many links at once that the new page is dominated by > your submissions.

> Off-Topic: Most stories about politics, or crime, or sports, unless they're > evidence of some interesting new phenomenon. Videos of pratfalls or > disasters, or cute animal pictures. If they'd cover it on TV news, it's > probably off-topic.</comment>


Ask HN: Why do Hackers always (it seems) go after Sony? - <AUTHOR>

Hey guys,<p>I read another article today http://www.bbc.co.uk/news/technology-30373686 where the Playstation network has been hacked. What is with all the hacks to Sony? Are they perceived to be easy to hack or are they a company that are for whatever reason hated? <comment><USER2> Hackers are always going after everyone. A lot of the vulnerability detection is automated, so really if you are vulnerable it's only a matter of time before you are exploited, and if you are a juicy target that timeframe is probably hours, not days.

Sony just seems to have more high-profile cases than others. Media companies tend to have a pretty devil-may-care relationship with security, and Sony has also done a few things in the past to earn people's ire.

</comment><comment><USER3> If you read the news, others have been hacked too like Home Depot, Target, etc.

Perhaps it is you focusing on Sony that is the issue, since others are getting hacked as well?

<comment><AUTHOR> I do read the news, and I am aware of the hacks on other companies.

Specifically I meaning this - [http://attrition.org/security/rant/sony_aka_sownage.html](http://attrition.org/security/rant/sony_aka_sownage.html) and the table at the bottom. Over 30-40 high profile attacks on a regular basis (every couple of months). And more recently hacks on the PS network, Sony pictures, customer details etc that were so high profile.

</comment></comment><comment><USER4> Ok, here are just two items of recent history:

[http://en.wikipedia.org/wiki/Sony_BMG_copy_protection_rootki...](http://en.wikipedia.org/wiki/Sony_BMG_copy_protection_rootkit_scandal) and [https://www.schneier.com/blog/archives/2005/11/sonys_drm_roo...](https://www.schneier.com/blog/archives/2005/11/sonys_drm_rootk.html)

      In the days after the rootkits were exposed, Thomas Hesse, president of
      Sony's global digital business, was quoted on NPR as saying, "Users don't
      know what a rootkit is, so why should they care about it?"

[http://en.wikipedia.org/wiki/PlayStation_Network_outage#Crit...](http://en.wikipedia.org/wiki/PlayStation_Network_outage#Criticism_of_Sony)

      Credit card data was encrypted, but Sony admitted that other user information
      was not encrypted at the time of the intrusion.[44][58] The Daily Telegraph
      reported that "If the provider stores passwords unencrypted, then it's very
      easy for somebody else – not just an external attacker, but members of staff
      or contractors working on Sony's site – to get access and discover those passwords,
      potentially using them for nefarious means."[59] On May 2, Sony clarified the
      "unencrypted" status of users' passwords, stating that:[60]

      While the passwords that were stored were not "encrypted," they were transformed
      using a cryptographic hash function. There is a difference between these two types
      of security measures which is why we said the passwords had not been encrypted.
      But I want to be very clear that the passwords were not stored in our database in
      cleartext form.

Bottom line is that Sony haven't helped themselves in the last few years. Whilst they build pretty good hardware, building software systems (especially to support things like the Playstation) isn't their forté. Worse is that when they do screw up, they are arrogant and disrespectful to their customers.

Their arrogance has irked a generation of hackers and script kiddies, who see Sony as a carte blanche target. The recent hack shows both their arrogance and negligent attitude to the security of their customer and private company data. Investors should be punishing Sony and calling for the heads of the board.</comment>


The Age of Surveillance Capitalism [video] - <AUTHOR> https://iai.tv/video/shoshana-zuboff-the-age-of-surveillance-capitalism? <comment><AUTHOR> HN discussion of the WSJ book review: [https://news.ycombinator.com/item?id=18908728](https://news.ycombinator.com/item?id=18908728)

The talk is 29 minutes total. I'd suggest watching from the 9m40s mark when the author starts talking about smart homes.

</comment><comment><USER2> Brilliant talk. She articulates what we already know really well. You don't even have to agree with her last thesis about privacy to oppose the commodification of your data.

</comment><comment><USER3> Thank you for not being hosted by (Youtube)

</comment><comment><USER4> She was the guest speaker on Le Show podcast last Sunday. If you enjoy her book or this video, the episode is worth a listen.

</comment><comment> sneeze-slayer I can highly recommend the eponymous book by the speaker. It is a long read, but a fascinating read. Here is a link to the publisher's page on it: [https://www.publicaffairsbooks.com/titles/shoshana- zuboff/th...](https://www.publicaffairsbooks.com/titles/shoshana-zuboff/the- age-of-surveillance-capitalism/9781610395694/)

</comment><comment><USER5> *I recommend starting at 9:40 and watching at 2x speed TLDR; increased revenue by 3950%; they can influence behavior (and confirm); your private experiences are for sale; it undermines democracy; epistemic inequality; we need to fight this by using browser extensions to block ads and tracking cookies; we need to be using duckduckgo.com for our internet searches; [https://en.wikipedia.org/wiki/Commodification](https://en.wikipedia.org/wiki/Commodification)

</comment><comment><USER6> This misnomer again? Certain companies monetizing user data has very little to do with capitalism and can barely characterize our age. Stop the dumb hate.

<comment><USER7> The term is useful, in that it distinguishes this (surveillance capitalism) from surveillance by _governments_ , which (until recently) was the usual form.

<comment><USER6> How are private companies synonym for capitalism? Capitalism is an economic order (characterized by the private ownership of the means of production and their operation for profit).

Would you say we live in the age of rocket ship capitalism because rockets used to be the domain of governments?

Overloading the term Capitalism may sound sensational, but it is not useful in explaining the issue.

<comment><USER7> > How are private companies synonym for capitalism?

> Capitalism is an economic order (characterized by the private ownership of > the means of production and their operation for profit).

I think you answered your own question.

> Overloading the term Capitalism may sound sensational, but it is not useful > in explaining the issue.

We're not. We're using surveillance as an adjective to modify capitalism, and thereby creating a new term.</comment></comment></comment></comment>


Lemonad: Functional JavaScript Library - <AUTHOR> http://fogus.github.io/lemonad/ <comment><USER2> I highly recommend "Functional JavaScript" by Michael Fogus (creator of Lemonad), [http://www.amazon.com/Functional-JavaScript-Introducing- Prog...](http://www.amazon.com/Functional-JavaScript-Introducing-Programming- Underscore- js/dp/1449360726/ref=sr_1_1?ie=UTF8&qid=1372302146&sr=8-1&keywords=functional+javascript)

<comment><USER3> It will arrive to my door this Friday, really excited to read it!

Concerning lemonad, since there's no documentation yet, I think the Annotation is really the way to go to get a quick feel at what the library has to offer: [http://fogus.github.io/lemonad/lemonad.html](http://fogus.github.io/lemonad/lemonad.html)

<comment><USER4> And the test specs as well [http://fogus.github.io/lemonad/test.html](http://fogus.github.io/lemonad/test.html)

</comment></comment></comment><comment><USER5> Another great project:

Bilby: Serious functional programming library for JavaScript [https://github.com/puffnfresh/bilby.js](https://github.com/puffnfresh/bilby.js)

<comment><USER6> Thanks for posting that. I'm quite impressed by what's in there, especially the bit of cleverness involved with the bilby.Do() syntax.

</comment></comment><comment><USER7> Lemonad was once much larger with a wider range of functional operators. Recently most of its functions have been moved into underscore-contrib ([https://github.com/documentcloud/underscore- contrib](https://github.com/documentcloud/underscore-contrib)). Most of my JS time lately has been spent with _.contrib, but I plan to come back to Lemonad soon and write up full docs and the like.

</comment><comment><USER8> [http://fogus.github.io/lemonad/lemonad.html#section-21](http://fogus.github.io/lemonad/lemonad.html#section-21) \- nice breaking bad reference [http://www.imdb.com/title/tt0903747/](http://www.imdb.com/title/tt0903747/)

<comment><USER9> Also lemonad is french for monad.

</comment></comment><comment><USER10> All these functions -with better docs- already exist in NPM.

<comment><USER11> Care to elaborate, or provide a link?</comment></comment>


Who's Afraid of Chrome? Flock 2 Released With Even More Bells And Whistles - <AUTHOR> http://www.techcrunch.com/2008/10/14/whos-afraid-of-chrome-flock-2-released-with-even-more-bells-and-whistles/

<comment><USER2> Does anyone here have any experience using Flock? I started reading the comments after the article, and was disappointed to see how close TC's comments are to youtube's.

Absent any other data points, it sounds like it would go great with: <http://news.ycombinator.com/item?id=325848> . At any rate it sounds like it's more relevant to the typical browser user than the Netscape Communicator suite was, so credit where credit's due.

<comment><USER3> I've been using it for a month. I blog, but most of my content is original, so I don't need the 'blog this' facility. The sidebar with Facebook status updates is nice, but nothing that couldn't be in a separate window.

</comment></comment><comment><USER3> Flock packages for Mint / Ubuntu / Debian can be found at getdeb.net</comment>


Ask HN: Conversion of Signups to a pre-launch page? - <AUTHOR> What is the conventional wisdom on signups to a pre-launch page? I'm have the conundrum of needing users to signup to justify business getting involved.<p>Should I achieve this with a pre-launch countdown and signup page? <comment><USER2> The conventional wisdom in the orbit of YC/HN has become acquire the first users one at a time by building something that they love and use. Worry about techniques that scale later.

However, the question seems to contain an ambiguity. Is your project ultimately focused on the needs of businesses or individual users?

My random internet person's advice, forget about sign ups. Forget about pre- launch. Build something basic and launch it to one person. Talk to that person. Launch the next iteration to two people. Iterate and launch to four. Keep going until you know it works or it doesn't.

Good luck.

</comment><comment><USER3> Are you asking about how many conversions you should expect, or whether this is a good way to validate an idea? Do you plan to ask for emails or an actual purchase?

</comment><comment><USER4> There is no conventional wisdom. It depends on your market, friction of signup and where you got your sign ups from.</comment>


The persistent fear of being exposed as a fraud - <AUTHOR> http://kodsnack.se/240/ <comment><USER2> Definitely a topic that needs to be discussed more often. Thanks for sharing.</comment>


Why you can't find a library book in your search engine - <AUTHOR> http://www.guardian.co.uk/technology/2009/jan/22/library-search-engines-books <comment><USER2> This is a good explanation of OCLC and its business model. I worked my way through about a year of my undergraduate degree program doing data-entry for OCLC back in the 1970s. I can gain OCLC WorldCat access from my home computer by logging in as a patron of my county library system, but it's too bad more people can't get the same functionality at a better known site without a log- in barrier.

</comment><comment><USER3> what I don't get...is why we don't have an online library

I mean seriously...if I can get a book for free from my public library, why shouldn't I be able to go to an online library website and get the ebook for free as well?

</comment><comment><USER2> I think anyone in the world can search the catalogs of Minnesota libraries through MnLINK.

<http://www.minitex.umn.edu/mnlink/>

</comment><comment><USER4> There was a strong flavor of Newspeak in the OCLC woman's explanation. Judging by that metric, at least, they seem to be the villains here.</comment>


Elite Korean Schools, Forging Ivy League Skills - <AUTHOR> http://www.nytimes.com/2008/04/27/world/asia/27seoul.html?ex=1366948800&en=99c8a3d39476256c&ei=5090&partner=rssuserland&emc=rss&pagewanted=all

<comment><USER2> It would be interesting to know what happens to these students once they actually get to Havard/Yale/Princeton. Do they find themselves able to cope in an environment where they have to learn on their own, without anybody to hold their hand? Do they run amok once they get out of that strictly controlled environment, and turn into drunken party animals? Do they become disillusioned when they realize that everyone around them is getting by just fine by putting in one tenth the effort? Or do they keep up the habit of insanely hard work, shoot to the head of their classes and go on to have stellar careers?

No doubt it's some combination of all of the above, but it'd be nice to know.

<comment><USER3> Having known graduates of both Daewon and KMLA at several elite colleges, I can say that their performance is comparable to most of the other students at their respective colleges. There are those who continue in their study habits and graduate at the top of the class, those that relax a little to explore their options and enjoy more of their college experience, and those that put more emphasis on socializing than studying. There's no real stereotype of a typical graduate from one of these schools, other than being smart, Korean, and communicating in fluent English. Most of them seem to be happy to be going to college in the U.S.

The craziest thing about most of this is that it takes just as much (if not more) effort for kids in high school to get to one of the top 3 Korean colleges (Seoul, Yonsei, Korea). In fact, both KMLA and Daewon also have a track for students who want to attend Korean universities that is just as intense.

It's hard to say whether this is the best way for a person to spend their high school years, but in places like Korea and Japan, this is the way that any college-bound student spends their youth. Everybody who wants to go to college either attends a college prep school or a private prep program from about middle school, because that's the way it has always been.

</comment></comment><comment><USER4> I worked with Koreans for a big project for a device manufactured by one of the big Koreans OEMs, where my company was providing some of the applications.

it was a problematic project, as the Korean wa having lots of bugs. The Korean guys worked everyday from 9:30 am, to 3:00 am! I am not making this up. And saturday, was only a half aday (8hrs) work. These guys were not getting enough sleep, and you would see often colapsed and taking naps in front of their computers. They were like walking zombies.

This was a important project, and I guess it is a cultural thing to work so much. Needless to say that their long hours were very counterproductive. They would fix something in the morning, and break something at night.

<comment><USER5> YES!

I absolutely do not understand why parents make their kids go through this torture. Thankfully I have very open minded Korean parents and grew up in the US, but right now I am in such a better position than half my parents' friends kids that it's not funny. I slacked off, did just the bare minimum until the subject interested me, I go to parties, I go to events, I have fun. I don't study until 5 in the morning unless it's a final I'm screwed for, or if I procrastinated way too much. In fact, if I ever stay up that late it's almost always because I've been spending too much time talking to the people on the opposite side of Earth on IRC while idly doing work or playing a game.

And well, I'm going to a better university than most of them, studying what I want to, earning well more than pocket change doing some coding work, and still having fun (and yes, a relationship! with premarital sex!). What did they do in the same 10 years? Study their asses off until they get burnt out constantly, and then go to some university studying what their parents wanted (half the time) or something socially acceptable (the rest of the time) where they still study their asses off, and then do the SAME thing at whatever job they get post-graduation.

I'm not being entirely fair here, but I'm not that far off. :\ It's quite depressing.

</comment></comment><comment><USER6> As Bush has shown very clearly, Ivy League skills have nothing to do with intelligence or even studying.

I think as long as asian universities and school focus on work so much and completely omit inter-personal skills, they will fail to to anything other than produce very smart people with no life.

Daniel

<comment><USER7> "Very smart people with no life"? Sounds a lot like working on a startup.

I grew up in the States, and I don't recall any university or school curriculum focusing on interpersonal skills.

<comment><USER6> You guys get show and tell sessions throughout school, don't you? In all of school until university I gave a grand total of 1 presentation to my peers. Then one more at university.

Daniel

</comment></comment></comment><comment><USER8> I don't agree with the methods and values described in the article, but these kids deserve a lot of respect for being able to master the English writing requirements. They are not native English speakers and are growing up in Korean society.

<comment><USER5> I disagree. Korean society idolizes the English language to the point that it's usually taught as a main secondary language starting from elementary school, and you pretty much can't get into any half decent Korean university if your English sucks. Of course, if you don't get into a nice university, you don't get a nice job because no big company paying the big bucks wants to hire you.

It's like the equivalent of saying "if you don't know English AND Spanish/French you're not getting into any university but the local shitty state/community college, which means low paying jobs for you!" in the US. And the society overall is so obsessed with English that they're using it as the main language in a lot of places (works great when half the audience doesn't know the language well, right?). I heard a broadcast of one commencement speech at some Korean university where some guy just talked in this horrible broken English that even I couldn't understand beyond a word or two (and I'm a native speaker and can usually understand people with heavy accents). Way to go! Isn't the point of a language to um, like, communicate? Not to alienate your non-English speaking but all fluent-in-Korean audience for the sake of attempting to look trendy by speaking English (but making a fool of yourself in the process..).

Of course, unless they get a job requiring English, or move to an English- speaking country, most people forget all they learned about English.

To top that off, given that I'm Korean, I get to deal with these (mostly) twats with no lives with a horrible command of English waay too often. Too many times I've been asked by friends of my mom who want me to tutor their poor kid cause I was in gifted programs since forever and have spectacular SAT verbal/writing scores. And I don't see anyone making any comments like yours about my excellent command of the Korean language (complete with slang) despite having been born and raised in the US. Or conversational French and Spanish. And Java. And Ruby. And C++. :p I respect any and all polyglots, regardless of where they were raised and what they know. But I just really felt the need to point out a couple of things.

Honestly, I should quit my job and give up coding to go teach English to the kids of the rich overseas. A couple hundred bucks an hour? Sheeeeesh. I already had to teach English to a couple of my cousins that came over last summer...the older one was considered to be one of the best English speakers in her expensive and elite private middle school but I honestly couldn't call it anything more than broken English at best.

</comment></comment><comment><USER9> I suppose it's a little bit better than StarCraft,

They really need to start teaching kids something other than book smarts though.

How much would you value creativity vs book smarts vs diligence when hiring people?

<comment><USER10> Not everyone is artistic. There is a market for people to come in to work, do something moderately intelligent for 8 hours, and then go home. I think this sort of school system prepares people for this sort of job pretty well. (I went to school in Japan for a year. I would much rather send my kids to school there than a random school in the US.)

Besides, creativity can't be taught. So you might as well focus on teaching things that _can_ be taught :) Eventually the creative people will realize that they should do something creative.

That said, a 15 hour school day is definitely excessive. You can pretend to learn for 15 hours a day, but you can't actually do it. I think 8 hours a day is the maximum amount of time you can focus on something that is not "interesting", hence the 8 hour workday that most people keep.

<comment><USER9> I wonder what would happen if instead of a steady 8 hour workday or school day it was broken down into four 2 hour periods. I tend to work better that way personally.

<comment><USER10> Well, 4 hours, lunch, 4 more hours :)

But if you mean more separation than that... it might be interesting, but most people don't want to commute 4 times a day.

Personally, I usually work for 6 hours, then I watch TV, relax, take a nap, etc. and then do some more work before really going to sleep. Very relaxing and productive. (Working at home is nice.)

<comment><USER9> Yea. Well at one point most of the non-facetime work should be done from home. I'm trying to ease myself into that now.

</comment></comment></comment></comment></comment><comment><USER11> Insane. Education is really, really, really important, but there's more to life than studying. Much more. Besides, the value of Ivy-League schools is overrated.

<comment><USER12> I doubt you will find many people that disagree there is more to live.

However, this is a short term sacrifice to achieve a goal. Many people would laugh at someone wanting to start a company on the side while working full time too. So let's not be too judgmental of their ambition.

<comment><USER11> But what's the goal? Getting into Harvard, Princeton, etc.? Because once they actually get in and reach their goal, they'll notice it's yet a long, long road to go.

</comment></comment></comment><comment><USER13> Looks like they gamed the system.

<comment><USER14> Studying 15 hours a day is not cheating - it is insane.

<comment><USER13> Well, it's not a permanent thing. It's a short term sacrifice for a specific goal. They are like athletes preparing for the Olympics.</comment></comment></comment>


Where Is the Best City to Live, Based on Salaries and Cost of Living? - <AUTHOR> https://www.citylab.com/life/2019/09/cost-of-living-best-worst-cities-housing-adjusted-salaries/597376/ <comment><USER2> The adjusted vs. unadjusted income numbers aren't actually all that helpful. What I want to know is the dollar number left over after standard expenses in each metro (i.e. basically discretionary income). Housing in a tech hub can eat up half your income, but if you've still got 20K more left over at the end of the year than you would in a smaller city with cheaper housing you're better off in the tech hub. Teasing that out of the presented tables in not straightforward.

See Disposable Income in [1] for a better take on this. Or even the older numbers from Citylab's own analysis [2].

[1] [https://www.cnbc.com/2019/05/22/people-in-these-cities- earn-...](https://www.cnbc.com/2019/05/22/people-in-these-cities-earn-worlds- highest-salaries-research-says.html)

[2] [https://www.citylab.com/equity/2011/12/us-cities-with- most-s...](https://www.citylab.com/equity/2011/12/us-cities-with-most-spend- after-paying-housing/778/)</comment>


This Developer's Life - <AUTHOR> http://thisdeveloperslife.com

<comment><USER2> oh, its a podcast! I couldn't tell at first. The front page is just images and captions, with no immediately visible info on what I am looking at. As the top center image is shoes, I thought it was some weird storefront... at least until I moused over something.

They might want at least a one-liner saying what that page is. There is such a thing as a design that is TOO minimal.

<comment><USER3> Absolutely true - I'll add that later this week! Edit: Fixed just now.

</comment></comment><comment><USER4> I LOVE this podcast. I think Rob and Scott do a great job of discussing areas of developers lives that are not generally talked about in a podcast. We don't always want to geek out and talk bits and bytes. TDL is a nice mix with some snappy musical interludes. Not to mention, they bring in some pretty big names in our industry.

Oh, I like the site too.

</comment><comment><USER5> This is my favorite podcast right now. The latest one, 'Typo', was amazing. Bill Hill was absolutely motivating, his passion is an inspiration.

<comment><USER6> The Bill Hill interview was amazing as always. The rest seemed to be a lot more filler than other episodes though.

</comment></comment><comment><USER7> This is pretty good. I've never seen the appeal of podcasts before but I'm enjoying <http://thisdeveloperslife.com/post/1-0-9-management> right now. I'm probably going to listen to the rest of them if this holds up.

</comment><comment><USER8> As a fan of This American Life (<http://www.thisamericanlife.org/>) I love this podcast, I've been listening to it for a while already I recommend "Audacity" and "Homerun".

</comment><comment><USER9> I enjoy this podcast very much, too bad Scott and Rob don't record more episodes... would love to hear a new episode every day!

</comment><comment><USER10> Arg! Sites that don't have an explanation of what they are anywhere drive me nuts. It's especially infuriating that it seems to be a collection of things that should be useful to developers, suggesting that they have good advice even though they can't manage the very basics on their own site, like stating somewhere what the site is about.

</comment><comment><USER11> This has easily become one of my favorites... big up to these guys for providing such an entertaining podcast.

</comment><comment><USER12> Not bad, but the sound quality lacks somewhat. Sometimes voices are saturated, sometimes there's a phaser effect (re-encoding problem?)... As a non native english speaker, these little things make the podcast quite harder to follow through, particularly in the noisy environment of a car.

</comment><comment><USER13> I recently had a couple long car journey's to take, and was recommended to listen to these podcasts as I went along.

Loved them, really quite interesting ... and made the journey's feel really quick! So thanks :)

A+++ Would listen again :P

</comment><comment><USER14> This is a fantastic podcast, I only wish they would put out episodes more frequently. I know that it's based on the format/style of This American Life, but honestly I think it's actually better.

</comment><comment><USER15> I just finished listening to the Typo episode. It was fantastic and was my first introduction to Bill Hill.

</comment><comment><USER16> I tried this podcast once - found it embarassingly pretentious, with terrible musical interludes set too high in the mix. Conery's speaking style really rubbed me up the wrong way. But I'll maybe give it another go. Maybe he's got it under control since then.

<comment><USER3> If the alternative is "rubbing you the right way"... I'll pass :). If you had the time to be a bit more concrete with your thoughts - it would probably help. I'm not an audio engineer, I'm a developer like you.

<comment><USER16> Don't worry, I'm not going to get all Christina Aguilera on your ass. Anyway, I do admire your ambition at attempting something a little different from the 'guys chatting' norm.</comment></comment></comment>


Scientific Proof Facebook is the Jersey Shore - <AUTHOR> http://www.seomoz.org/blog/scientific-proof-facebook-is-the-jersey-shore <comment><USER2> when someone calls 'Scientific Proof' it should at least have some reference or description how it was analyzed.</comment>


Show HN: Bucket Query – Automatically index and search your AWS S3 buckets - <AUTHOR> http://www.bucketquery.com <comment><USER2> Why does the marketing on the site not make a comparison with Athena?

<comment><AUTHOR> Founder here. Great thought. We had toyed with the idea of a comparison chart/table aired on the side of simplicity. Based on your feedback it might make sense. We'll see how we can incorporate something like this on a future website update.</comment></comment>


Almost absurd literary math puzzle - <AUTHOR> What is the probability that someone is an only son of an only son of an only son? <comment><USER2> I'll start by assuming that the "someone" is male (if not, multiply the answer by 1/2).

What's the probability that this person is himself an only son? I don't know that it's logically derivable - couples have a variety of numbers of children, of various mixes of genders. So far as I can see, that probability can be measured but not derived. Call that probability P.

If I had to estimate it, I'd say that the most common number of children is two, and of the four possibilities (BB, BG, GB, and GG), half of the boys are only sons. (This is presuming that a sister doesn't ruin "only son" status.) So that leaves the probability at 50%. Tweak that with only children (100% of male only children are the only son) vs. more than 2 children (reduces the probability of being an only son), but the probability is reasonably somewhere in the neighborhood of 50%.

The probability we are looking for is P^3 (presuming that only-son-ness is not something hereditable, that is, that the probabilities are independent in each generation. So the total probability is something like 1/8 = 0.125 (or 1/16 if we don't know that the "someone" is male).

Have I missed something here?

<comment><USER3> That sounds right, as far as it goes. (I likewise assume a sister doesn't ruin 'only son' status, and that we don't know someone is male).

Another line of thought, possibly just a line of confusion:

Assume "someone", S, _is_ the OS of an OS of an OS. Look at the siblings of S's grandfather - he could have had any number of sisters, but had no brothers. The probability of that situation occurring goes down with each increase in the number of sisters. So maybe an exact answer can be given, a formula including terms for the number of sisters each of the 3 OSs have? (not forgetting the probability that S is also female)

<comment><AUTHOR> Someone can be an only son regardless of the number of sisters he has

<comment><USER3> >Someone can be an only son regardless of the number of sisters he has

Yes, that's what my point was - "he could have had any number of sisters" \- if you have 12 sisters, it's extremely unlikely you are an only son. The more sisters, the more unlikely being an only son is.

<comment><AUTHOR> Yep, but the whole trick is finding a model that estimates the percentage of the male population that are 'only sons' at 0,1, and 2nd generation level.

</comment></comment></comment></comment></comment><comment><USER4> This is no more absurd than asking how many golf balls fit into a bus. It seems impossible but with a few assumptions you can get a good enough ballpark.

<comment><AUTHOR> That's why I wrote "Almost"</comment></comment>


Ask HN: How dominant is VMWare (as of Aug 2016)? - <AUTHOR> In enterprises big & small VMs have become ubiquitous. Ecosystem around the OpenStack still seems to be pretty fragmented with not many good enterprise ready end to end solutions. For the IT Orgs is it all VMWare or public cloud (AWS, Azure etc.) ? How dominant VMWare really is ? <comment><USER2> I can't answer the question as to how dominant VMware is, in the entire market.

I can say that ever single company I've worked for has used VMware for their virtualization solution.

I also use it for my business. It's pretty much ubiquitous, if you ask me.

That said, I don't expect it to stay that way forever.

<heavily opinionated part>

Some folks say KVM performs better, but I haven't seen much difference in my experience.

That, and KVM has little/no polish. Certain things are much more difficult to do with KVM, like create a VM with anything other than a NAT interface.

There are LOTS of tools available for VMware.

There just seem to be a lot of things that make VMware one of the easiest solutions to go with. I think ubiquity is part of that. If you're running something on VMware, and you want to relocate VMs, it's easy to do so.

OpenStack - also messy, and not very easy to learn. I'd love to learn it, as I hear folks with OpenStack skills can make bank. It seems like a jumbled mess, though, and I have no idea where to start. </heavily opinionated part> :D

<comment><USER2> After rereading my comment, wrt to the parts about KVM... I realizing I may have been trying to use KVM in a manner other than how it was intended to be used.

Initially, my experience with virtualization was just desktop products. Now I run a vSphere host in my home office, and admin several clusters for work.

I have read elsewhere that KVM is basically just the plumbing for the virtualization, and I was trying to use it with a front end like virt-manager, and KVM is basically just the back end piece.

I'm prepared to be corrected/educated on this. Open mind here.

Definitely have a bias to VMware, but I'd like to know more about the competition.

</comment></comment><comment><USER3> I've seen about 50/50 VMware/Hyper-V in my travels. I mostly deal with manufacturing companies in the US. They're very Windows centric, which, I imagine, is why Hyper-V comes up so often. Virtually none of them want to touch anything cloud based; there's a lack of trust and potential legal issues depending on what they're making. Cloud platforms targeted toward government might change that. The more forward thinking small/mid sized operations seem to be moving towards some cloud based products, but the industry is behind the times.

Can only speak from experience within US manufacturing. Don't apply this beyond that.

<comment><USER2> The legal worries about putting stuff in the cloud are much more apparent with companies outside of the US, in my experience.

Was formerly part of a US company that was pushing a new product _hard_ towards a cloud-based model. They were expecting a particular foreign customer to go for it.

The customer said "NO WAY. EVER."

</comment></comment><comment><USER4> VMWare is probably ubiquitous in large enterprises.

Small and medium IT shops probably lean towards an open source based solution like KVM.</comment>


The EXT4 Corruption Issue on Linux 4.19 Is Caused by BLK-MQ - <AUTHOR> https://www.phoronix.com/scan.php?page=news_item&px=Linux-4.19-EXT4-Issue-Likely-MQ <comment><USER2> Good to see progress on this, I'd hate to have to trouble-shoot this one.

From Bugzilla, sounds like ZFS is affected, but can correct it:

> In my case (kernel 4.19.6 and a 2-vdev/6-drive raidz1) doing an rsync > to/from the same ZFS filesystem would generate ~1 error every 5s or so (on a > random drive on the pool).

(ZFS still manages to surprise me, with some of the shortcomings it's easy to forget how often it's saved me, although in this case I'm not running 4.19)</comment>


Show HN: Radi v0.8 - my HTML5 animation app now has brushes, shape poses, etc. - <AUTHOR> http://radiapp.com/whats_new_in_v080.php

<comment><AUTHOR> I've finally finished another update to my Radi app. It's a Mac design tool that can be used to produce animation and videos, with output to HTML5.

This update adds a number of tools that hopefully make the app more useful for real work. The big one is frame-by-frame animation of shapes, so you can do traditional 2D animation. There's also new support for Markdown blocks with an integrated style editor, so you can easily edit rich text that becomes clean HTML.

I've also updated the landing page somewhat: <http://radiapp.com/> ... There's now a comparison box with other HTML5 animation editors, and more screenshots. Would love to hear your comments about it...

<comment><USER2> I struggled to find the demos from a deep-linked page. I think a nav item called "examples" would be handy. It's the most important thing I want to see with this kind of software, as the proof is really in the pudding.

Also investing the time in creating some more impressive animations would really sell this to people. If you don't have the knack for it yourself, outsource it to a designer or, dare I say it, make a competition out of it.

<comment><AUTHOR> There's a handful of examples at the top of the landing page (blue box with heading "Watch some examples"). Is it poorly placed or too small maybe...? I'll add a nav item for it to the menu.

Anyway, I hear what you say about the need for impressive examples. I don't have the talent for that; my current examples are certainly not too interesting.

I guess I'll have to invest some money into it... (Since Radi is free, it's not making me anything, and so far it's been strictly a hobby project. Maybe it's time to take it a bit further.)

<comment><USER3> Any future in porting it to Win? Any inspiration from Adobe Edge? I am happy that there are more and more potential replacements for flash in this respect, hopefuly this will also make it easier for versioning control and branch merges.

<comment><AUTHOR> I made a preliminary effort towards a Windows port a few months ago. It's running, but not really usable.

Here's a screenshot: <http://radiapp.com/radi-windows-sshot-20110805.jpg>

I haven't looked deeply at Edge since the initial release. One fundamental difference is that Radi's output is completely custom rendering into either <canvas> or <video>, while Edge uses CSS for animation. I wrote a blog post about that with lots more detail: [1]

Although there's some overlap, the approaches are basically complementary. Hence I'm hoping to make Radi into not so much a competitor to apps like Edge and Hype, but rather a more creation-oriented tool that can be used together with these other apps that focus more on building entire sites.

Now that e-books are becoming basically HTML5 packages, I'm hoping to find some opportunity for Radi in that market as well... But I haven't done any deeper research into that yet.

[1] <http://lacquer.fi/pauli/blog/2011/08/why-radi-uses-canvas/>

<comment><USER3> Wow nice, great Blog post, that should be a HN link in it's self! I will be watching for an windows version and keep up with your twitter/blog.

</comment></comment></comment></comment></comment></comment><comment><USER4> For a hobby project, it is awesome and impressive. Things like this light a fire under my ass, and remind me I need to get cracking and start something awesome like this.

Congrats.

<comment><AUTHOR> Thanks :)

To be fair, I didn't start from scratch because a substantial part of Radi is in frameworks that I originally made for Conduit Live, my bread-and-butter product [1]. I've been working on it for about 5 years, and with Radi, I was exploring the idea of doing something "webby" with these imaging/video software pieces that I had at hand.

[1] <http://lacquer.fi/conduitlive.html>

</comment></comment><comment><USER5> this is awesome. any ideas of open sourcing, licensing, price range etc.? you could market this as a competitor to the recently announced iBooks Author

</comment><comment><USER6> You need a big, blue "Download BETA!" button.</comment>


Reducing Python's startup time - <AUTHOR> https://lwn.net/Articles/730915/ <comment><USER2> To be clear. I never said that start-up time wasn't important. Instead, I pointed out that in the previously studied example, the measured impact on start-up time of a single named tuple was a fraction of a millisecond and less than 0.1% of start-up time.

At Guido's behest, I agreed to treat this miniscule component of start-up time as being important and will review and implement some optimizations in the sprints next week. I've agreed to do this even if it comes at the expense of code clarity, complexity, or maintainability. I expect that when I'm done, _source will be a lazily generated attribute and that much of the code currently in the template will be pre-computed. This seems reasonable to me.

FWIW, I've devoted 16 years of my life to optimizing Python and care a great deal about start-up time. I'm not happy about all the Raymond bashing going on in this thread.

<comment><AUTHOR> Thank you Raymond for all your great work.

Regarding this post and related comments, I would like to say that, as an external observer who does not know the details of CPython development decision-making process, phrases such as "Okay, then Nick and I are overruled" and "At Guido's behest" sound not so good to my ears.

Maybe you and Guido are best friends, and you are half-joking with that tone, or maybe you are responsible for that part of code, so it is your duty to change it according to BDFL last words even if you do not agree with them... I do not know. Anyway I think it would be better, in the open source world, if a code change is developed by someone who thinks it is the right thing to do, or I could not see so much difference from commercial companies and proprietary software.

Hey, just my two cents. Keep rocking! :)

<comment><USER3> I liked those comments, and I thought they reflected well on Raymond. It's a sign of a healthy technical organization that contributors are willing to disagree and still heed decisions made by those higher in the decision-making chain.

</comment></comment></comment><comment><USER4> namedtuple is particularly weird. When you create a new type of namedtuple, Python creates the source code for a new class from a string template and passes it to exec() to build the class. It's a clever and relatively straightforward bit of metaprogramming, but it's not a suprise it's not fast. [https://hg.python.org/cpython/file/b14308524cff/Lib/collecti...](https://hg.python.org/cpython/file/b14308524cff/Lib/collections/__init__.py#l236)

(BTW if you need a quick and dirty way to make Python start up faster, see if you can use the -S flag for your application. It skips the site-specific initialization and has a significant impact on startup times.)

<comment><USER5> I'm curious, given the presence of a ".pyc", shouldn't these kinds of costs be paid primarily on first invocation "ever"?

<comment><USER6> No, because the string given to eval will not be stored in the pyc – it has to be compiled on every import.

<comment><USER7> It can't be cached? Is not caching a dependency issue?

<comment><USER8> It can't, because lol dynamic dispatch. Exercise: what does this code do?

        import collections
        collections.namedtuple = lambda _0, _1, _2=False, _3=False: "Where is your god now?"
        import b

b.py:

        import collections
        print(collections.namedtuple('Point', ['x', 'y']))

And this is not even particularly 'evil' code, in the sense of relying on internal implementation details; that's just your bread-and-butter Python language semantics. It prevents (or at least complicates) many other potential optimisations as well.

</comment></comment></comment></comment></comment><comment><USER9> I'd been wondering why _source was in there. I'm a little surprised that Hettinger thinks it's so important to retain it. It's a neat demonstration of how to make a new data type, and I like that it's so straightforward, but I don't buy the argument that slowing down the interpreter is important for didactic reasons.

Edit: I'm talking about namedtuple, the implementation of which is slow because namedtuple() has to construct _source for every new namedtuple type. Which was clear from the article but not from my comment.

<comment><USER2> One purpose of _source is to make the namedtuple self-documenting -- that has been a considerable benefit over the years and has resulted in many fewer questions and issues than we usually get about our other tools.

Another purpose of _source is so that you can write it out to a module. This lets you pre-compute the named tuple for speed and it makes it possible to easily Cythonize it or to customize it (in particular, people like to take out the error checking).

Since the namedtuple() factory function was already creating the source string as part of its operation, just storing it and exposing the attribute had nearly zero additional cost.

That said, don't worry about it, next week I plan to make this a lazily generated attribute so you all can sleep soundly at night :-)

<comment><USER10> Does this mean you're changing how Namedtuples are implemented, or just not saving _source?

</comment></comment></comment><comment><USER11> Seems like this article is inflammatory and totally unnecessary.

It is written in a way to pin a blame on someone (Raymond H) and also looking at python-dev (and even on the github issue) the decision was made month earlier (July) to go with the optimization[1], and Raymond complied[2].

[1] [https://mail.python.org/pipermail/python- dev/2017-July/14860...](https://mail.python.org/pipermail/python- dev/2017-July/148606.html) [2] [https://mail.python.org/pipermail/python- dev/2017-July/14861...](https://mail.python.org/pipermail/python- dev/2017-July/148611.html)

</comment><comment><USER12> I have grown to seriously dislike 'namedtuple'. It seems great, and it's so easy to use, but there's so few places it can be used without dragging in future backwards-compatibility baggage.

Let's say you have a light-weight object, like a "full name" which can be represented with a "forename" and an "surname". (Yes, there are many names which don't fit this category. This is a toy example.) So you write:

      from collections import namedtuple
      FullName = namedtuple("FullName", "forename surname")
      name = FullName("Edward", "Smith")

So simple! So clean! No "self.forename = forename" or need to make your own __repr__.

Except you also inherit the tuple behavior, because this isn't really light- weight object but a ... let's call it a heavy-weight tuple.

      >>> name[0]
      'Edward'
      >>> name[1]
      'Smith'

This mean people may (okay, are likely) do things like:

      forename, surname = name

or even

      for forename, surname in names:
        ...

Even if that's not what you want in your API. If you care about backwards compatibility, then if you replace the namedtuple with its own class then you'll have to re-implement __getitem__, _replace, __len__, and count - methods which make no sense for a simple name class.

Or, if you decided to change the API, to make it be:

      FullName = namedtuple("FullName", "forename middlename surname suffix")

then you'll again break code which used the full indexing API that you originally implicitly promised, simply by saying this is a namedtuple.

'namedtuple' has one good use - migration from a tuple object to a real object while allowing backwards compatability to the tuple API. For example, the old tuples once returned from os.stat() and time.gmtime().

It's also fine if it will only be used by code where you have full control over its use and can either prevent inappropriate API use like destructuring assignment, or can update all uses if you want to change the API. For example, a light-weight object used in a test-suite or internal helper function.

Otherwise, don't use it. Spend the extra few minutes so in the future you don't have to worry about backwards compatibility issues.

<comment><USER13> Only if one is misusing namedtuple: it should be used for iterable things, like csv lines, db rows, coordinates, etc. but not for a person. That makes no sense.

If what you need is a cheap, quick container, then you want types.SimpleNamespace.

<comment><USER12> "but not for a person. That makes no sense."

I wrote 'toy example' for a reason. While it does not make domain sense, it's easy to understand and it highlights the problems I wanted to show.

"it should be used for iterable things"

Really? This article concerned the use of namedtuple in

      functools.py
      21:from collections import namedtuple
      403:_CacheInfo = namedtuple("CacheInfo", ["hits", "misses", "maxsize", "currsize"])

The cache_info() method returns a _CacheInfo instance to the user. Where/what are the "iterable things"?

If a future version adds another attribute, it will break most code which uses destructuring assignment.

(For that matter, I can't see why it make sense to use a namedtuple for this case. Why not just:

      class _CacheInfo:
        def __init__(self, hits, misses, maxsize, currsize):
          self.hits = hits
          ...

? Who cares about immutability here?)

Or for another case, here's a Python function which returns a class derived from a namedtuple:

      >>> from urllib import parse
      >>> result = parse.urlparse("http://www.python.org/")
      >>> for term in result:
      ...   print(result)
      ...
      >>> for i, term in enumerate(result):
      ...   print(i, repr(term))
      ...
      0 'http'
      1 'www.python.org'
      2 '/'
      3 ''
      4 ''
      5 ''

Again, where is the "iterable thing"? I mean, the ParseResult instance is iterable, but my point is that it makes no sense to iterate over those fragments.

If the Python standard library gets it wrong, what is the right solution?

"If what you need is a cheap, quick container, then you want types.SimpleNamespace. "

You mean the one where the documentation at [https://docs.python.org/3/library/types.html#types.SimpleNam...](https://docs.python.org/3/library/types.html#types.SimpleNamespace) says "SimpleNamespace may be useful as a replacement for class NS: pass. However, for a structured record type use namedtuple() instead." ?

I do not think you are correct.

<comment><USER13> There are plenty of issues with the stdlib. Part of it don't respect the PEP8, there are inconsistencies with argument types and orders, some of it is even unusable for real life usages (ex: csv in python 2.7) and we keep it for legacy reasons.

The fact is, the use cases you are showing are wrong, and the one I'm talking about are the proper ones. It's ok to make mistakes, we all do a lot of them. And we will have to pay for those.

If you are interested in the subject, last month we had a huge debate on the Python mailing list about a way to have a proper official immutable but non interable structured record to replace named tuple and avoid those abuses. And also to maybe include something like attrs in the stdlib.

<comment><USER12> It would be nice if you could show me a proper example, as what you wrote doesn't match with my understanding of how it is used nor with how it should be used.

My argument is to resist the temptation to use namedtuple for anything except a migration from tuples to named attributes. While there is some overlap with what you wrote, they are not the same. I would like to know what I'm missing.

<comment><USER13> A proper use for namedtuple:

        @property
        def coordinates():
            x = self.calculateX()
            y = self.calculateY()
            return x, y

this could become:

        Point = namedtuple('Point', ('x', 'y'))

        @property
        def coordinates():
             x = self.calculateX()
             y = self.calculateY()
             return Point(x, y)

It stays compatible with the previous implementation. as you can still do:

        x, y = stuff.coordinates

But now can do:

        point = stuff.coordinates
        point.x

The same example apply for a row a from timeseries in a database or a line of stats in a csv.

But now imagine you have a response from a ldap server returning a list of authorized person. You could manipulate those persons in a dictionary. Some people may want to have a nicer way to access them, with the look up syntax. You can be tempted to use a namedtuple here, but that make no sense, as a person is not iterable. The alternative is to use empty class, but it's very verbose.

But now you can use types.SimpleNameSpace:

        >>> class Person(types.SimpleNamespace): pass
        >>> p = Person(name='foo', age=12) # no __init__ to write
        >>> p # free repr
        Person(age=12, name='foo')
        >>> p.age # nice access syntax
        12

The good thing is that if you ever need to extend Person to later have a more complex behavior, you can just do so as it's a regular class.

The bad things are:

\- you may need something immutable

\- you may want some checks done to restrict the attributes used

Which is why currently people abuse namedtuple. We don't have a good story for those. Hence the debate on the mailing list.

Nevertheless, it's good to remember that the Python community has a philosophy of "we are all consenting adults here" and a good track record for following it. immutability and attributes restrictions are not definitive show stoppers in Python, and SimpleNameSpace is a decent solution while waiting a purer to come up.

<comment><USER12> Your example with Point() is exactly what I said was a good use case, for apparently the same reasons why I said it was a good use case.

I said "'namedtuple' has one good use - migration from a tuple object to a real object while allowing backwards compatability to the tuple API. ... It's also fine if it will only be used by code where you have full control over its use and can either prevent inappropriate API use ... Otherwise, don't use it."

You replied "Only if one is misusing namedtuple".

I interpreted this as an objection to my use guidelines. From what I can tell, you are in complete agreement with me.

</comment></comment></comment></comment></comment></comment></comment><comment><USER5> Moving "import" statements into dynamically-controlled blocks goes a long way in my experience, despite being flagged by tools like "pylint".

Buried imports free the interpreter from doing something until it is actually required; really nice if you just want to run "\--help" and not wait 4 seconds for utterly unrelated modules to be found. It also creates this interesting situation where a script can technically be broken (e.g. module not found) but you don't _care_ as long as the _part_ you're using is OK.

Grouped imports are undoubtedly nice for purity and easily seeing dependencies but they may not be smart in a dynamic language. It is still pretty easy to "grep" to find imports if you're trying to track dependencies.

<comment><USER10> Would be nice if CPython had an option to enable "lazy imports".

</comment></comment><comment><USER14> One side benefit to removing the use of "eval" is that namedtuples will then be pickle-able. I'm surprised this hasn't come up: every now and then I hit some weird data I want to quick-and-dirty serialize but can't because there's a namedtuple buried deep inside it.

<comment><USER15> Namedtuples are pickle-able when created in the global scope, just as any dynamically created class. The main section of the collections module demonstrates that feature (read the source, Luke).

Removing eval from tuple would not solve your issue. You'd need to instead remove eval from pickle, of sorts. The trouble is that pickle tries to look up your namedtuple by name and can't find it in your module.

</comment></comment><comment><USER16> One of the comments below the article mentions this, but in my experience on Linux and Mac, by far the biggest culprit is pkg_resources and its nasty habit of spidering the filesystem:

[https://github.com/pypa/setuptools/issues/926](https://github.com/pypa/setuptools/issues/926)

There are hacks to get around it, but it's a deep hole.

<comment><USER17> People often complain that using `entry_points` in setup.py is slow. I did some profiling and it came down to it importing some `pip` submodule (pip.vendor.something), which imported basically the whole of pip.

:(

</comment></comment><comment><USER18> Mercurial did a lot of work to reduce startup time via its demandimport module.

[https://www.mercurial- scm.org/repo/hg/file/tip/hgdemandimpor...](https://www.mercurial- scm.org/repo/hg/file/tip/hgdemandimport/demandimportpy2.py#l1)

Basically, it's a lazy loading of all imports. You can write `import foo` but it won't actually be imported until you do `foo.whatever()`.

It's a crutch, and it's true that hg still pays the overall startup cost of Python. However, even with "45 times slower than git", the situation is not so dire:

      jordi@chloe:~$ time hg --version
      Mercurial Distributed SCM (version 4.2.2)
      (see https://mercurial-scm.org for more information)

      Copyright (C) 2005-2017 Matt Mackall and others
      This is free software; see the source for copying conditions. There is NO
      warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

      real	0m0.096s
      user	0m0.084s
      sys	0m0.008s

      jordi@chloe:~$ time git --version
      git version 2.1.4

      real	0m0.001s
      user	0m0.000s
      sys	0m0.000s

I really can barely perceive a difference between 0.096s and 0.001s. Since it really is a one-time startup cost, it's not like we can even say that this difference accumulates and that hg is overall 45 times slower than git.

Pierre-Yves also has an interesting talk about all of the tricks that have to go into hg in order to make it fast with Python. There's stuff like doing `method = object.method; method()` instead of doing `object.method()` over and over again to avoid paying the cost of method lookup and so forth:

[https://2015.pycon.ca/en/schedule/53/](https://2015.pycon.ca/en/schedule/53/)

<comment><USER19> > _I really can barely perceive a difference between 0.096s and 0.001s. Since > it really is a one-time startup cost, it 's not like we can even say that > this difference accumulates and that hg is overall 45 times slower than > git._

It's bad for many things -- like showing VCS status on your shell prompt or IDE status line, where you repeatedly start hg.

100ms+ delay every time you hit enter in your shell is noticeable (and that's just the version, now doing an actual "dirty" check takes more).

<comment><USER20> Mercurial has something called command server[1], it's essentially a daemon listening on sockets to receive commands, designed just to avoid the cost of startup. I had to use it once in a CI system where we did invoke hg thousands of times for some reason i can't even remember.

That can also be used for frequent polling like shell status.

[1] [https://www.mercurial-scm.org/wiki/CommandServer](https://www.mercurial- scm.org/wiki/CommandServer)

<comment><USER21> In fact I have hg locally aliased to chg and have not noticed any issues with it. Just much faster command completions and an actually usable shell that includes hg annotations.

</comment></comment></comment></comment><comment><USER22> BDFL says:

> Concluding, I think we should move on from the original implementation and > optimize the heck out of namedtuple.

I remember reading this on the mailing list and thinking "yes, namedtuple deserves optimization because it's an excellent resource".

For my use cases, I don't think I notice Python's startup time. When I write Python code it's usually not performance critical. When I do write performance-critical Python code, I usually care about total runtime and PyPy is usually a win here. Aside: if you use PyPy, you should probably be using namedtuples. IIRC it models those much better than it does dicts. And IMO namedtuples model many common data structures better than dicts do.

Just because I don't feel the pain of Python's startup time doesn't mean we shouldn't try to optimize it. I think I find my way into some esoteric Python/CPython corners but FWIW I've never needed namedtuple's "_source" attr.

<comment><USER16> Ruby's idea of a hash where the keys are colon symbols seems to really strike a sweet spot here— it's fast and storage-efficient like a tuple, but has the flexibility of a dict.

<comment><USER9> One big advantage of using namedtuples, aside from the immutability I mentioned elsewhere, is that you can rely on a namedtuple having particular fields. So if you're using dictionaries, you have to worry about KeyError wherever the dict is used, but if you're using namedtuples, you can't create them without assigning values to all of the fields. Dictionaries are still great for their intended purpose -- to represent a mapping -- but namedtuples are nicer if what you really want is a lightweight object.

<comment><USER16> Setting default values for the namedtuple requires subclassing it, though, which is its own little bag of fun. See all the wailing and gnashing of teeth on SO: [https://stackoverflow.com/search?q=namedtuple+subclass](https://stackoverflow.com/search?q=namedtuple+subclass)

<comment><USER23> If you're using Python 3.6, it's a lot easier now. You can do:

from typing import NamedTuple

class Point(NamedTuple): x: float y: float = 0.0

and then Point(1.0).y == 0.0.

<comment><USER9> That's quite nice!

</comment></comment></comment></comment></comment></comment><comment><USER24> > The approach of generating source code and exec()ing it, is a cool > demonstration of Python's expressive power

Man, I don't see many positive opinions of exec out there.

> I think we should move on from the original implementation and optimize the > heck out of namedtuple. The original has served us well. The world is > constantly changing. Python should adapt to the (happy) fact that it's being > used for systems larger than any of us could imagine 15 years ago.

I really wish the BDFL could say the same for CPython itself. This continued insistence of treating python as a teaching language with a teaching implementation is really weird.

</comment><comment><USER25> Raymond Hettinger, if I remember correctly, is the person who originally wrote NamedTuple, and he's not shy about reminding people during his talks at conferences. I wonder if his pride or other personal feelings about that particular module could be clouding his judgment over whether or not to optimize it?

<comment><USER26> I think it's more to do with him primarily teaching python (iirc) rather than working on large systems with it.

It's the same strain of rant Zed Shaw had of Py3, ie., that its harder to teach than Py2 and thef. bad. Crazy.

EDIT: OK, if not primarily teaching, spending a lot of his time teaching it. That's a big part of his motivation + worth knowing that when assessing his arguments.

<comment><USER27> > It's the same strain of rant Zed Shaw had of Py3, ie., that its harder to > teach than Py2 and thef. bad. Crazy.

Why is wanting something to be easy to teach crazy?

<comment><USER26> Programming languages are tools for developers. They are taught in the service of software development. Optimizing for teaching has it backwards.

It can be a factor: but to place it higher than startup time is prioritising the one-off teaching experience of a few over the repeated development experience of many. For a tool _for_ development. Crazy, no?

<comment><USER28> Ability to teach is going to be directly correlated with ability to maintain as a business. It's harder to hire people when the bar for learning the skill is higher.

The vast majority of software development is not hitting any kind of scaling or performance bottlenecks. So optimizing for simplicity isn't as crazy as you think.

<comment><USER26> I think python's start up time is going to correlate much more strongly with business success than whether Raymond's 12th slide in his 16th deck requires five minutes more time.

<comment><USER29> Absolutely not. Python always had a suboptimal performance story relative to other languages, but people use it anyway.

Businesses use Python because it is easy to pick up, not because it's fast

</comment></comment></comment></comment></comment></comment></comment><comment><USER30> > The approach of generating source code and exec()ing it, is a cool > demonstration of Python's expressive power

This sentence is very surprising to me. If the best way to implement something is to literally build a _string of source code_ and pass it to the interpreter, to me it means the user is unable to really express what they want in the language.

As a (terrible) example, imagine a language whose number addition operator only works on literals.

        1 + 2
        => 3

        a = 1
        b = 2
        a + b
        => ERROR!

It does, however, have a string concatenation operator that also works on variables and a way to read user-provided numbers into a variable, as well as some kind of eval function. What would you do to add two user-provided numbers? Something like the following:

        foo = read number!
        bar = read number!
        baz = concatenate x, ' + ', y
        quux = eval baz

The same thing could be stated about this language...

> The approach of generating source code and eval-ing it, is a cool > demonstration of <this language>'s expressive power.

...but it clearly wouldn't make sense. Functions like exec and eval are an escape hatch for when there is no sensible way of expressing something in the language.

<comment><USER31> I'd say that the existence of an escape hatch for things that can't be expressed natively is itself a form of expressitivity. It's one that's near ubiquitous among dynamically typed languages, so it doesn't say much that Python has it, but it still provides a favorable comparison to some static languages.

That said, this particular use case for eval is basically macros lite: the code being evaluated doesn't generally depend on input to the resulting program, so it could have been expressed as a transformation to the module source code, i.e. a macro. And a true macro would be able to provide more natural syntax, whereas namedtuple requires stuffing the field names into a string (or using a wrapper based on some metaclass thing, but the syntax for that isn't great either). Thus, languages that have macro support, both dynamically typed (Lisp) and statically (e.g. Rust), could be called more expressive in this respect.

</comment></comment><comment><USER32> Ah, slow startups on unittests is a big headache. This is especially apparent on big projects like Django where you might as well leave your desk and grab coffee when the unittests start, even for small projects. That said, I can't help but think that this is just an inevitable tradeoff of Python. You want great expressive power? You have to sacrifice speed. Awesome constructs like namedtuple make this worth it imo.

<comment><USER33> I can't help but think if a one-time initialisation cost is bogging a process down, there are bigger problems than that initialisation cost.

<comment><USER19> There are processes that you might need to run frequently. I gave an example above: showing the output of a Python script on your shell prompt (e.g. mercurial status).

<comment><USER34> I moved from Python to Go for rendering my shell prompt for much the same reason: [https://blog.bethselamin.de/posts/latency- matters.html](https://blog.bethselamin.de/posts/latency-matters.html)

<comment><USER19> Funnily I did exactly the same -- rewrote parts of a powerline (shell prompt status enhancements) implementation that I used and was written in Python, and turned it into Go.

But it still has to call into Python to get my mercurial status (we use mercurial at work so I need to have that).

</comment></comment></comment></comment></comment><comment><USER35> I agree with optimizing Python's startup time, and I agree that namedtuple is weird and should be changed.

But I doubt that the namedtuple change will noticeably decrease startup time for most applications (after having experience with this problem for 10+ years).

From a comment over 3 years ago:

 _[Python interpreter startup does] random access I /O (the slowest thing your computer can do) proportional to (large constant factor) x (num imports in program) x (length of PYTHONPATH)._

[https://news.ycombinator.com/item?id=7842873](https://news.ycombinator.com/item?id=7842873)

I don't think that instantiating a Python parser 100 times for exec() is going to compare to that. I guess the difference is that I'm thinking about the cold cache case -- namedtuple might be noticeable in the warm cache case.

And there are many many command line tools that start slow because they're written in Python, not just Mercurial.

Mercurial is actually one of the best because they care about it (demandimport) and they don't have too many dependencies. IIRC some of the Google Cloud tools take 500-1000+ ms to start because they are crawling tons of dependencies with long PYTHONPATH.

<comment><USER12> If you are really interested in improving the startup cost then the first thing is to put everything, including the Python standard library, into .zip files, so it can be zip imported. That removes a lot of the directory/stat overhead. The comment you pointed to did not do that optimization.

For example, I supported a 10 year old set of CGI scripts running on a machine with Lustre filesystem where every filesystem metadata lookup was painfully slow. (See ehiggs' comment at lwn.) I spent time to trim away every import to the bare minimum.

Once you do that, other factors become more significant. (Remove your biggest problem and something else becomes your biggest problem.)

If the view is that a few milliseconds here and a few milliseconds there isn't a problem, well, those milliseconds add up.

'import scipy' (which depends on numpy) takes 3x longer to import than Python itself does. I have replaced dependencies on scipy when the overhead of importing the one function I needed took longer than my program took to run.

There's an old story along these lines, recounted at [https://www.folklore.org/StoryView.py?story=Saving_Lives.txt](https://www.folklore.org/StoryView.py?story=Saving_Lives.txt) :

> One of the things that bothered Steve Jobs the most was the time that it > took to boot when the Mac was first powered on. ... One afternoon, Steve > came up with an original way to motivate us to make it faster. ...

> "You know, I've been thinking about it. How many people are going to be > using the Macintosh? A million? No, more than that. In a few years, I bet > five million people will be booting up their Macintoshes at least once a > day."

> "Well, let's say you can shave 10 seconds off of the boot time. Multiply > that by five million users and thats 50 million seconds, every single day. > Over a year, that's probably dozens of lifetimes. So if you make it boot ten > seconds faster, you've saved a dozen lives. That's really worth it, don't > you think?"

How many people use Python? How many times is it started per day?

<comment><USER36> The other way around this is containers or caching filesystems.

</comment></comment></comment><comment><USER37> At my company we changed the interaction between two daemons by calling a command line script instead. It caused a 300ms delay in every single AJAX call and broke a dozens of end-to-end tests.

I just tried with Python 2.7 and 3.6 and the hello world startup time is 100ms which is awful lot.

</comment><comment><USER38> I suspect one factor for why Go is so popular within Google is that (due to complex path hacks as mentioned here as well as a network file system) Python startup is so slow.

On an app I worked on the unit tests took >10 seconds to boot on each run. Among the languages available to Google developers, Go ends up being the lightest weight, despite there being plenty of other lighter languages available outside. (This is not the place to start an argument about language plurality.)

</comment><comment><USER39> I feel like the namedtuple issue could be solved cleanly by adding a feature I've wanted for a long time in Python: some simple way to cache high-level data and code in generated .pyc files. Today, there's no way to do that; Python compiles the code but evaluates nothing until execution time. I'd like my .pyc files to contain some precomputed expressions and code, to reduce startup time. I probably ought to discuss this on python-ideas.

</comment><comment><USER40> If the namedtuple is used so heavily, why not make it a part of built-in functions?

</comment><comment><USER41> It's funny. Go on #python on freenode and ask a question about named tuple. Consensus there is that they should be avoided in favor of real classes or attrs decorated classes.

</comment><comment><USER42> It's unfortunate that the new version still creates __new__ using exec(). Doesn't seem necessary at all. Instead of generating the method as a string with the argument names filled in, why not use use a combination of * n and * * kw?

</comment><comment><USER43> IMHO this namedtuple is non-issue compared to buildout.

buildout tends to append millions of path to os.path

Annnnd your python project start time requires 1 minute or more because each import requires scan millions of directories.

</comment><comment><USER44> My question is, is it worse or better with Ruby,NodeJS, Perl,Java or Go? I remember NodeJS scripts being extremely slow to start in general, way slower than Python.

<comment><USER34> Sorted from slowest to fastest: (all single measurements on my Arch Linux notebook)

      $ time java &> /dev/null
      java &> /dev/null  0,09s user 0,03s system 120% cpu 0,102 total
      $ time ruby -e 42
      ruby -e 42  0,04s user 0,01s system 99% cpu 0,053 total
      $ time python -c 42
      python -c 42  0,03s user 0,00s system 98% cpu 0,030 total
      $ time perl -e 42
      perl -e 42  0,00s user 0,00s system 92% cpu 0,005 total

I don't have NodeJS at hand to test with. Note that Java produces a help message (which I sent to /dev/null), but that (hopefully) shouldn't affect the timing that much.

Go produces compiled binaries and, as such, exhibits no such startup delay. Startup times for Go programs that I tested are in the same ballpark as Perl above, i.e. not reasonably measureable with a millisecond-precision tool like time(1).

</comment></comment><comment><USER45> heh, when I read it, I thought it was about reducing _Java_ startup time to be on par with Python's.

</comment><comment><USER46>
        $ time python -c ''
        real	0m0.071s
        user	0m0.064s
        sys	0m0.000s

        $ time python -c 'import functools'
        real	0m0.073s
        user	0m0.052s
        sys	0m0.016s

I mean...

<comment><USER47> It's not exactly a reliable benchmark for many reasons...

</comment></comment><comment><USER48>
      $ time python -c 'print(1)'
      1

      real	0m0.067s
      user	0m0.015s
      sys	0m0.025s

Is it slow? That was Python 2.7.10, and for me Python 3.6 is similarly fast.

<comment><USER49> On my system (macOS) I see a minimum of 0m0.034 for Python 3.6.1 and a minimum of 0m0.022 for Python 2.7.13 -- so Python 3.6 is 50% slower.

This is a somewhat contrived example, however. As the article notes, it's worse when you have a lot of imports (and I don't know how that'd differ between versions 2 and 3). I remember talking to some folks at Google who work on the Google Cloud CLI, and they said that Python startup time is a constant problem for their (large) codebase. Especially when it's used for tab completion, because it might run every time you press tab, and the user wants instant results.

<comment><USER16> We're dealing with this on a CLI build tools project I hack on (catkin_tools). It uses plugin discovery based on entry_points, and short of caching plugins in a homedir file, it's basically impossible to make it fast enough to use with something like argcomplete.

Relevant ticket: [https://github.com/catkin/catkin_tools/issues/297](https://github.com/catkin/catkin_tools/issues/297)</comment></comment></comment>