Better HN
topnewbestaskshowjobs
Log inSign up

apendleton

4,277 karma · joined Feb 29, 2012 (14y ago) · 994 submissions

Submissions

comment 13y ago · link · parent

A blog post that's probably not worth linking to, since apparently it was wrong.

Am I correctly inferring that you need at least a Last-Modified in the response to do a cache-conditional request, though?

comment 13y ago · link · parent

Right, the question was why not use a conditional get, which either returns content if the thing has been modified, or a 304 Not Modified and no content if it hasn't -- this accomplishes the same thing as HEAD with only one request. Above, though, I wasn't sure why one or the other wasn't always used...

I looked it up, though. It looks like you have to have an ETag to do a conditional GET, so browsers use HEAD if the original response (the cached one) didn't include one.

comment 13y ago · link · parent

I've definitely observed both behaviors in Firefox, and to be honest, I'm not entirely sure why. I'll see what I can dig up...

comment 13y ago · link · parent

Two reasons, I think: one (as a sysadmin once explained it to me) is that there's a certain degree of public good/advertising that comes from publicly supporting an open-source project by advertising that you use it in your headers. Services that aggregate web server market share (Netcraft, etc.) use the Server header to build stats.

It's also not that hard to fingerprint webservers (though not necessarily their specific versions) without making use of the Server line by testing for other subtle differences in behavior (see, for example, http://82.157.70.109/mirrorbooks/apachesecurity/0596007248/a... ). So on balance, hiding the version makes it hard to single you out for vulnerabilities in specific versions, but hiding the server name altogether doesn't really add much.

comment 13y ago · link · parent

This is probably over-broad. HEAD is also used by browsers to determine whether or not to re-request cached content; disabling it will still allow pages to load properly, but will waste bandwidth and slow down page loads as browsers re-request unchanged content.

OPTIONS is necessary if you want to offer APIs that support CORS: http://en.wikipedia.org/wiki/Cross-origin_resource_sharing

comment 13y ago · link · parent

Yeah, that's the key, I think. Netflix has a huge amount of viewing-habit data at their disposal, and it's tough to imagine that they didn't target their content acquisitions based on detailed information about their viewers. House of Cards was for the HBO/West Wing set, and Hemlock Grove clearly isn't, but they must know that there's a dedicated audience of schlocky TV-horror enthusiasts in their viewership.

comment 13y ago · link · parent

They're doing that anyway because they serve non-webp images to users with non-webp-supporting browsers. Anyhow, this is the image that's for display, which is resized/compressed; they store and allow you to download the original no matter what.

I'm skeptical of this solution for other reasons, though (like that it assumes users know what JPG means).

comment 13y ago · link · parent

Love the idea, but seems a little too fly-by-night for me to want to trust real production stuff to it. DDoS-ing DNS providers seems to be the rage these days, and I'd hate to be collateral damage because the weekend project I was using as a DNS provider couldn't handle it...

And I totally get that this was just for fun... but a variant project that still used git as the UI, but sat on top of a bigger-player DNS provider's API (Route 53, maybe?) could probably give you the best of both worlds: a weekend's worth of hacking, but still using infrastructure people felt like they could trust.

comment 13y ago · link · parent

I don't work there, but I doubt it. With rendr, both the client- and server-side portions of the Backbone stack still need to consume an upstream API. If I had to guess, I'd say that for projects they're building that use this stack, all the templating/rendering/presentation logic is in JS, but that the database interaction stuff probably isn't; they probably have Rails apps that expose a RESTful API that the rendr apps consume.

comment 13y ago · link · parent

qSA does a lot more than class and id selectors; those have been trivial since long before qSA came along. You can also do selection on element attributes, parent-child selections (include strict child selection with ">"), and a few other higher-order selector combinations.

Still, I don't mean to slight Sizzle, and certainly won't stop using it. It's just nice to see jQuery compete with Zepto, since apparently there's a demand for a build that small, and jQuery is better-tested and less brittle.

comment 13y ago · link · parent

Depends what you're doing. If you're building a mobile app (particularly one meant to be distributed via PhoneGap), or a Chrome extension, maybe you don't care about IE support.

comment 13y ago · link · parent

No, the idea has pretty much always been that jQuery 1.9 and 2.0 would be feature-comparable, just with different sizes and supported browsers. See http://blog.jquery.com/2012/06/28/jquery-core-version-1-9-an...

comment 13y ago · link · parent

The addition of the ability to just use querySelectorAll as the selector engine and not ship Sizzle is a pretty big deal, and not something I remember being included in earlier discussions about jQuery 2. qSA still includes a pretty broad set of selectors, and the ability to get the build down to 10k minified and gzipped puts it squarely in Zepto's territory, size-wise, eliminating the need for that particular wheel reinvention.

comment 13y ago · link · parent

The article recommends using MongoDB as a primary data store, so South wouldn't be applicable (and that's specifically addressed).

comment 13y ago · link · parent

> Use Gunicorn instead of Apache for your webserver

This is strange advice; while you can use gunicorn as a front-facing webserver, the gunicorn docs strongly recommend against doing so. In a typical deployment scenario, then, gunicorn and Apache would occupy different levels of your stack, with one running your WSGI app and the other exposing it to the world. The advice ought probably to be "Use gunicorn+nginx instead of Apache+mod_wsgi," and indeed, lots of people do make that recommendation about Django deployment.

comment 13y ago · link · parent

This option probably wins on cost and ease of use. For technically-minded people that can afford CrashPlan, though, this product may not be compelling; that's okay. Not all products are right for all people.

comment 13y ago · link · parent

But they talk about the "how" (the EME) as a done deal, when they don't seem to be, given Mozilla's opposition; more people will have to be convinced for this to actually work. Besides, everyone knows their proposed "how" already. A blog post that just says want to move to HTML5 delivery using this set of extensions they've already publicly supported for this purpose doesn't add much to the discussion.

comment 13y ago · link · parent

Probably not, but then why say anything at all? The omission is conspicuous.

comment 13y ago · link · parent

Writing a technical article about the standards process around web DRM without even obliquely addressing any of the criticism of it seems like a strange choice to me. Almost everything in this article was already publicly known; what I'd like to have seen was an actual rebuttal of the criticisms of, among others, Ian Hickson, so as to move the standards conversation forward.

comment 13y ago · link · parent

Patent trolls buy them and keep them to use them eventually, but will wait a long time before doing so so that lots of members of industry will have infringed before starting to sue. In trademark law, you can't do that: if you're lax and let your mark become generic, it's basically impossible to go back and go after infringers after the fact (this happened to "nylon," for example).

There would still certainly be patent trolls, but as a start-up, you wouldn't have to worry as much about them... if you wanted to implement a feature that other companies were also implementing, you could do so with a reasonable amount of safety: either they weren't patented, or they were and there would be noisy lawsuits going on about them, or the patents existed but were no longer valid due to lack of defense.

comment 13y ago · link · parent

Would there be any obvious problems with defend-it-or-lose-it laws around patents, like there already are around trademarks? Seems like it would kill the submarine-patent market entirely, and would discourage companies from bothering to file for patents they didn't plan on vigorously defending (I could imagine drug companies continuing to file; software companies, not so much).

I don't tend to hear this suggested in patent-reform discussions, though, so I assume there's a reason not to go this route.

comment 13y ago · link · parent

What makes you think this is a recent realization? World War II was financed in large measure with war bonds, which are also just debt.

comment 13y ago · link · parent

A month ago this would have seemed perfectly sensible, but if this is just a platform for experimentation and data-gathering, why do another city? Austin is apparently similar in demographics to Kansas City, so I'm not sure you'd get considerably different results, and I can't imagine KC is too small to provide a reasonable sample... seems like there has to be more going on here than that.

comment 13y ago · link · parent

Cool, thanks. I'll probably run one of my projects' benchmark set later today to see how this stacks up... I suspect that if some of the numpy and cffi stuff is enough faster, I may still be better off on this release than the last. Either way, gevent support seems worth it to me. Kudos on the release.

comment 13y ago · link · parent

But when you say "independent campaigns," what you're really talking about is "independent campaigns that happen to attract the attention of very rich people." Most would-be independent candidates don't get that, and are consequently unable to compete against the candidates (independent or otherwise) who do attract high-dollar donors. There's an undeniable bias in which candidates ultimately get selected as a consequence.

If that bias favors the kinds of insurgent candidates you tend to favor, lucky for you I guess, but I'm not sure how that supports the argument that this is good for democratic processes generally.

comment 13y ago · link · parent

What's the nature of the performance regressions? Is everything just universally 5% slower, or did the benchmark scores drop by 5% because some particular operations/workloads are slower in this release? If the latter, which ones?

comment 13y ago · link · parent

Right, I definitely don't think PyPy+[ctypes|cffi] is universal ("many," not "all"). Lots of people are doing Cython. Also, anyone who has a performance-sensitive workload that depends on SciPy is out of luck on PyPy at least for the time being. All I'm saying is that PyPy as a performant-Python strategy is common enough now that it's worth supporting in new performant-Python projects.

comment 13y ago · link · parent

This looks really slick, but it's a bit unfortunate that this was implemented in a way that's tied to the CPython API specifically, given that there are Python-VM-neutral methods of low-level interop available (ctypes, CFFI, etc.). My general sense (and certainly my own experience) has been that many people doing speed-sensitive Python work are already running on PyPy now, and that writing lower-level extensions has become a way to squeeze out an extra level of performance beyond that, so having to go back to CPython to take advantage of this infrastructure would be kind of a bummer, and almost definitely a non-starter in my projects, which leaves me stuck with C.

comment 13y ago · link · parent

Yes, I completely agree. Having the icon be a floppy disk is only weird during this transitional period when there are software users that regularly used floppy disks and now recognize them as antiquated. Most of the youngest generation of current computer users have probably never seen a floppy disk, so for them, that symbol (like the phone) just means "save," rather than being a representation of an actual thing. Eventually it will probably become more stylized and less recognizable, as people forget what it originally meant.

comment 13y ago · link · parent

I think I said something similar on the first round, but for the Python tests, I'd be curious to see alternate runtimes and/or concurrency strategies: pypy, gevent, and probably the confluence of the two (though it requires quite a bit more hacking, since gevent doesn't officially support pypy).
1
282930
34