Application Cache Is A Douchebag
alistapart.com
alistapart.com
So are redirects to your own domain, though not quite the same as here. What it means that while downloading the resources specified in your manifest file, encountering a 302 means that the entire applicationCache fails. Downloaded 99 static files fine, and then get a 302? Congratulations, your cache is now invalid.
> GOTCHA #9: AN EXTRA HOOP TO JUMP THROUGH FOR XHR > You can make XHR requests to cached resources while offline, unfortunately older versions of WebKit finish the request with a statusCode of 0, which popular libraries interpret as a failure.
Not that much older. This is the case for iOS5.1, the last time I checked, and for every Android phone I've tested this on as well.
As for GOTCHA #9, I thought that was fixed in iOS4. But yeah also fails on Blackberry playbook and Andorid 3 & 4. Actually works on Android 2.3 (unless I'm mistaken), which isn't suprising as there are loads of regressions in the Android 3 browser.
Spent a few days on it. Worked great online. Then I discovered that putting /illustration/17 in the cache manifest made the entire thing fail, since it's a redirect.
C'est la days of wasted work.
I've built an appcache app that is a bunch of static javascript (in the CACHED section) contacting a bunch of services in the NETWORK section. There is no FALLBACK section, because any resource is either online or offline, but never both. The UI is designed so the user knows which content is online, and can decide for themselves if they have good enough connectivity. Dynamic content goes into localstorage if it needs to be persisted. This way of using appcache works very well and is mostly painless.
I think more worders should matriculate into the Strongbad School of Verbinizin' Speechy Things.
This section is not quite true, at least for WebKit. This article states that the application cache will use the normal browser cache when making outgoing requests, honoring whatever cache control headers were sent by the server. What actually happens is that the browser always forces a revalidation of the content with the server, regardless of what the cache control headers that had been served.
Now, I certainly /wish/ it were the case that it honored the normal browser cache, but it simply doesn't. The result is that the application cache makes these outgoing requests painfully and arduously one-at-a-time, waiting for the previous one to entirely complete before making the next one... over a mobile data connection this takes /forever/, and it is quite possible that it simply does not finish by the time the process is aborted by one of these needless server requests failing or the window being closed.
Normally, you can mitigate these issues by sending files with "cache this effectively forever" headers and always using unique filenames, but with the application cache manifest system (which you are going to be using to support guaranteed-consisten offline operation) you are forced to wait for every request to resubmit before seeing the update.
Here is the code from WebKit's ApplicationCacheGroup.cpp, where you can see "max-age=0" being sent as Cache-Control for the outgoing requests. (Sending that header as a user-agent serves to "force any intermediate caches to validate their copies directly with the origin server", per RFC2616).
PassRefPtr<ResourceHandle> ApplicationCacheGroup::createResourceHandle(const KURL& url, ApplicationCacheResource* newestCachedResource)
{
ResourceRequest request(url);
m_frame->loader()->applyUserAgent(request);
request.setHTTPHeaderField("Cache-Control", "max-age=0");See http://www.youtube.com/watch?v=q7QL0NAwES8 - All files are "must-revalidate" except the JS file which is far-future cached. When the manifest is changed an update is triggered, all files are updated except the JS file, which is assumed to be fresh because of the far future expiry.
You see similar behaviour when no caching headers are served, heuristics take over & files may be updated from the normal browser cache rather than going to the server.
(edit/clarification: While I get this code from the WebKit repository, I forgot that the specific area of WebKit I'm looking at is WebCore, so I should really be calling it WebCore and not WebKit, considering they are separate libraries and quite separate projects on some platforms.)
Someone else I know (who may or may not decide to actually chime in) saw this interaction and decided to do some tests with various browsers, stating that 1) Safari worked as I said, 2) Firefox refetched the request but did not set the Cache-Control header, and 3) Chrome worked as you say.
Most professionals will no longer bother to read an article with a headline that uses insulting, sexist words.
If you worked for me and wrote that title for an article about something we were working on, you wouldn't work for me any more. Period.
Tech culture is moving away from childishness, and there were a large number of other words you could have used in your title.
Go learn some.
I think you have to let this one go. Fighting against linguistic churn as a proxy for "sexism" seems to me like it hurts more than it helps, as it feeds the "PC feminazi" meme. There are better fights to pick than this one.
http://www.quora.com/English-language/When-did-the-term-douc...
Seems like its use as a nickname/insult really exploded in the 70's and 80's. I'd tend to agree that tying the word to sexism is a bit of a stretch--it's probably just being used because it sounds like a naughty word, and anything more explicit or profane wouldn't get past the censors.
I agree with the bad choice of the word "douchebag", which seems juvenile, but I disagree with it a) being sexist, and b) the general idea that swear words are somehow generically "childish" or "unprofessional". It's puritan approach to language, and largely an American issue. In fact, I would call that particular attitude "childish".
There's nothing inherently wrong with swearing in an opinion piece.
I agree that these words have no place in a professional working environment. But I still read articles with bad words. (Actually, it's why I clicked on it in the first place!)
Just my take.
I have fantasies of doing a web comic at some point. Should that ever work out, the standard I have in mind is that it should be "Night Court"-esque in nature. In spite of frequently having "adult" themes it was implicit, not explicit, in nature. My 24 year old son has said that when he watched "Night Court" as a child, he thought Dan was some loser who talked a lot of crap but saw almost no action. When he saw the same show when he was older, he was surprised to realize that wasn't the case at all. Why was he even able to make the comparison? Because the show was acceptably "clean" that I did not hesitate to let a young child watch it. That translates to a much larger potential audience than the "adults only" material.
Besides, I taught my sons from an early age that swearing was not "adult" behavior but was simply rude: http://www.kidslikemine.com/manners.shtml
pavel_lishin brought up a great example above: sucks. To most people under the age of 30, it is categorically not swearing. It is not even slightly naughty. It's informal in much the same way that "totally sweet" is, but it's not dirty. But many people older than that will insist that it's swearing. True story: Once, when I was working on my college paper a few years ago, we used "sucks" in a headline. The faculty adviser flagged the headline and questioned whether we wanted to use swearing there. Every single student there was baffled by what she meant.
I am aware that words like "retard" or "stupid" can be just as problematic as words like douchebag, cock, or dick. But in this instance, I think it conveys what I mean better than any other word I could use. I am not against the use of strong or loaded words on principle. I just think unnecessary use of such language is a good way to shoot yourself in the foot. I can't imagine someone wanting to lose audience members or even risk losing them without good reason.
I am guessing you didn't read my blog post on the topic. That might explain why I am baffled by your reaction.
Take care.
One of the tickets in our tracker is titled "Appcache Sucks". My boss actually e-mailed me Jake's article with the e-mail subject, "Sounds like something Pavel would write."
We use naughty words here at work, and nobody gets their undergarments in any sort of embedding of the circle into three-dimensional Euclidean space.
"Once an article is published containing either edgy or profane language, a comment will inevitably derail the conversation to usage of profanity."
This is a professional site, for a (hopefully) mature, professional audience.
Step 1: Grow up and learn to write mature, professional articles. I didn't bother to read it because of the headline.
"Most professionals" live and work within ten miles of this: http://www.youtube.com/watch?v=z5MGJ87hPGw. If you worked for me and weren't comfortable with this kind of diversity, I'd cap your ass. Period.
Tech culture keeping it realer every year. Throw down some rude JS or get your app-cache timed out. That's the way we live and die in the 415, neighbor!
Edit: Seriously, the person with the potty-mouth might be an awesome developer and you'd be an idiot to not hire or fire them for being a little non-PC. The swearing at least indicates some level of passion for their work, which is most likely a good thing. Personally some of my best work was done on projects where I alternated between the occasional, but rare, out-loud 'fuck yeah!' and 'fuck you package x, why do you have to be this way?!'
Guess what? There are lots and lots and lots of awesome programmers out there. We don't have to chose the immature ones to work with.
Odds are he'd probably regret the title later, all on his own, and really that's more than enough. Or maybe not- he based the title off his opening story, which I found amusing. Hardly a fireable offense, not even worth a reprimand really.
Somehow, an article describing caching of web applications manages to denigrate women, for no reason.
The underrepresentation of women in tech is caused by this mindless sexism, like body-shaming women. Douche bag is a sexist insult. You're insulting your target by associating them with feminine care products. It's a direct associating between "This thing is womanly so it is bad." Even after several other stories these digs at women still get publicized!
To each his own.
Although I am not a fan of the word, calling this article unabashed support for sexism is a bit much.
If you break out the pitchforks and torches at even minor infractions more moderate people will grow tried of it.
There is real sexism out there, and it should be addressed. This isn't it.
At the core of this argument is the idea that the "popularization" of act of douching itself was itself anti-woman, insofar as it categorised normal women's bodies and actions as unclean and shameful, and in turn advocated an unhealthy "solution" to a problem largely invented by the patriarchy.
Nevertheless, I cringed ever-so-slightly when Jake gave this talk at JSConf and again when I saw it here on HN, because I knew that in recent months, among all the other salient gender issues that have been floating about, a bunch of people also "heard douchebag was sexist," and so would lodge this reservation.
Not using douchebag is easy! Step 1) Just Don't! Now you won't have to deal with causing strife with women in tech.
Modern medicine considers douches to be dangerous to use. Not sure how making a negative of something that is, in fact, negative is a bad thing.
I don't think it's reasonable to say that people shouldn't use the words "douche bag".
Of course it isn't. But it's part of a larger culture you have a vested interest in maintaining which is why you need to defend it.
Defending douchebag is about defending the right to be carelessly and callously offensive without needing to think of others in the community.
Because if I want to be a careless, self centered, unsympathetic human being then that's my right and how dare someone point out I might be harming others!
And the author did expect those accusations which is why in his blog comments he links back to month old comment of his on hackernews where he defends his right to be offensive.
I reread my comment and I didn't call anyone a dick. I checked the article and it doesn't use dick either.
I suppose you're after some false equivocation here which means you don't quite understand how women are being actively repelled from the tech industry. Using language hostile to a minority group is exclusionary. "Dick" as an insult in a male dominated group is not.
I'm not arguing that the author is right to use douchebag; he was trying for entertainment value but to me it came across as unnecessary. But getting worked up because he chose the wrong insult out of the many, many insults we have relating to both male and female body parts and functions is silly.
It's the only way to encourage positive change. I see you'd prefer to ignore it, but that just perpetuates the hostile culture that has ingrained itself over decades.
He could have gone with anything (asshole for instance!) but chose to Other women and likely not intentionally, which is still no excuse.
You are free to ignore the sexism just as much as you were free to ignore my comment, but for some reason you decided to step in and defend the article from my negative rated comment.
Which is insulting to donkeys.
EDIT: The problem is that you need to pick your battles. His word selection, out of all the possible sexist terms was quite possibly the least sexist out of all the sexist terms he could have used. On the whole, considering that the sexism of the term douchebag is still an unanswered question, it's hard to find fault.
Below is a list of alternative curse words you can use instead of 'douchebag'. Please note that the great majority of them are sexist, racist, or religious blasphemes. If you have a list of non-offensive profanity we should use, please comment and i'll add them to the list with a special note.
Edit: pastebin'd for posterity
ahole, anus, arse, arsehole, ass, ass-hat, ass-jabber, ass-pirate, assbag, assbandit, assbanger, assbite, assclown, asscock, asscracker, asses, assface, assfuck, assfucker, assgoblin, asshat, asshead, asshole, asshopper, assjacker, asslick, asslicker, assmonkey, assmunch, assmuncher, assnigger, asspirate, assrammer, assshit, assshole, asssucker, asswad, asswipe, axwound, ayir, bampot, bastard, beaner, bitch, bitchass, bitches, bitchtits, bitchy, blowjob, boffing, boiolas, bollock, bollocks, bollox, boner, boob, brotherfucker, buceta, bullshit, bumblefuck, butt-pirate, buttfucka, buttfucker, butthole, buttplug, buttwipe, cabron, cameltoe, carpetmuncher, cazzo, chesticle, chinc, chink, choad, chode, chraa, chuj, cipa, clit, clitface, clitfuck, clusterfuck, cock, cockass, cockbite, cockburger, cockface, cockfucker, cockhead, cockjockey, cockknoker, cockmaster, cockmongler, cockmongruel, cockmonkey, cockmuncher, cocknose, cocknugget, cockshit, cocksmith, cocksmoke, cocksmoker, cocksniffer, cocksucker, cockwaffle, coochie, coochy, coon, cooter, cracker, crap, cum, cumbubble, cumdumpster, cumguzzler, cumjockey, cumslut, cumtart, cunnie, cunnilingus, cunt, cuntass, cuntface, cunthole, cuntlicker, cuntrag, cuntslut, dago, damn, daygo, deggo, dego, dick, dick-sneeze, dickbag, dickbeaters, dickface, dickfuck, dickfucker, dickhead, dickhole, dickjuice, dickmilk, dickmonger, dicks, dickslap, dicksucker, dicksucking, dicktickler, dickwad, dickweasel, dickweed, dickwod, dike, dildo, dipshit, dirsa, dominatrix, doochbag, dookie, douche, douche-fag, douchebag, douchewaffle, dumass, dumbass, dumbfuck, dumbshit, dumshit, dupa, dyke, dziwka, ejakulate, ekrem, ekto, enculer, enema, faen, fag, fagbag, fagfucker, faggit, faggot, faggotcock, fagtard, fanculo, fanny, fart, fatass, feces, feg, felcher, fellatio, feltch, ficken, fitt, flamer, flikker, flippingthebird, foreskin, fotze, fuck, fuckass, fuckbag, fuckboy, fuckbrain, fuckbutt, fuckbutter, fucked, fucker, fuckersucker, fuckface, fuckhead, fuckhole, fuckin, fucking, fucknut, fucknutt, fuckoff, fucks, fuckstick, fucktard, fucktart, fuckup, fuckwad, fuckwit, fuckwitt, fudgepacker, futkretzn, gay, gayass, gaybob, gayboy, gaydo, gayfuck, gayfuckist, gaygirl, gaylord, gaytard, gaywad, god-damned, goddamn, goddamnit, gooch, gook, gringo, guido, guiena, handjob, hardon, heeb, hell, helvete, ho, hoe, homo, homodumbshit, honkey, huevon, hui, humping, injun, jackass, jackoff, jagoff, jap, jerk-off, jerkass, jerkoff, jigaboo, jism, jizz, junglebunny, kanker, kike, klootzak, knob, knulle, kooch, kootch, kraut, kuksuger, kunt, kurac, kurwa, kusi, kyke, kyrpa, lameass, lardass, lesbian, lesbo, lezzie, lipshits, mamhoon, masochist, mcfagget, merd, mibun, mick, minge, mofo, monkleigh, mothafucka, mothafuckin', motherfucker, motherfucking, mouliewop, muff, muffdiver, muie, mulkku, munging, muschi, nazi, negro, nepesaurio, nigaboo, nigga, nigger, niggers, niglet, nutsack, orifice, orospu, packie, paki, panooch, paska, pecker, peckerhead, penis, penis-breath, penisbanger, penisfucker, penispuffer, perse, picka, pierdol, pillu, pimmel, pimpis, piss, pissed, pissedoff, pissflaps, pizda, polack, polesmoker, pollock, poon, poonani, poonany, poontang, poontsee, porchmonkey, prick, pula, pule, punanny, punta, pussies, pussy, pussylicking, puta, puto, qahbeh, queef, queer, queerbait, queerhole, rautenberg, rectum, renob, retard, rimjob, ruski, s.o.b., sadist, sandnigger, schaffer, scheiss, schlampe, schlong, schmuck, screw, scrote, scrotum, semen, sharmuta, sharmute, shemale, shipal, shit, shitass, shitbag, shitbagger, shitbrains, shitbreath, shitcanned, shitcunt, shitdick, shitface, shitfaced, shithead, shithole, shithouse, shitspitter, shitstain, shitter, shittiest, shitting, shitty, shiz, shiznit, skank, skeet, skribz, skullfuck, skurwysyn, slut, slutbag, smeg, smut, snatch, son-of-a-bitch, sphencter, spic, spick, spierdalaj, splooge, spook, suckass, suka, tard, teets, teez, testicle, thundercunt, tit, titfuck, tits, tittyfuck, turd, twat, twatlips, twats, twatwaffle, unclefucker, va-j-j, vag, vagina, vajayjay, vittu, vjayjay, vulva, wank, wankjob, wetback, whore, whorebag, whoreface, wichser, woose, wop, yed, zabourah
And here I thought we were professionals and not children, but apparently offending peers in a professional setting is acceptable to you.Also nice of you to cowardly admit that this stuff is inappropriate and hide it in a pastebin after you regretted posting it here. I'm going to leave your word vomit here. If you don't have the backbone to leave it in I think that just proves my point that it's inappropriate and should not be spread used in professional circles.
Honestly I pastebin'd it because it took up an entire page of screen real estate which is really annoying for everyone else to have to scroll past just for me to make a point. I had the "backbone" to pastebin it, so I don't see how not pasting it in-line makes me less-backbone-y.