skysight-inc/HackerNews huggingface dataset:
I once worked for a failed startup, where the CEO insisted that we needed to write code to deal with billing people on arbitrary days of the month. I really wanted to do it on just the first of the month unconditionally, because I didn't think this was a good use of our time [1], but I was overridden.

I had a Perl library that was much like the Ruby one, where it could add a month. Having by then caught the unit testing bug, I wrote my billing code, with just a couple lines as the payload, then wrote myself a unit test that simulated a customer joining us on any of the possible 731 days they could do so (365 days in a non-leap year, 366 in a leap year), then ran through two years of billing, validating that we billed them on a day as close as possible to the correct day (i.e., Feb 28th if you were on a 30 cycle), never missing a bill or double-billing.

Sounds simple, right?

In my nearly 20 years of coding, this is the single most frustrating bit of code I have ever tried to write and debug. Just absolutely unbelievable. Billing code that worked perfectly, except on months with 30 days joined in a leap year. Billing code that worked perfectly, except if you joined on a 31-day month that was followed by another 31-day month (which is July, but the bug was essentially caused by that problem). And no matter how I beat the code, no matter how I fixed one bug, some other blasted corner case popped out.

Even now as I write this, I say to myself "surely this isn't that hard of a problem"... but it was. It really should have worked, but it didn't.

Calendars are evil.

And, what prompted me to reply, it would have been really easy for any version of this code to ship and not be noticed for a long, long time, if I hadn't written the exhaustive test cases I did. There was code that literally worked in 99.5% of the cases, and would only have broken a couple of times a year, and probably would have been written off as flukes or mysteries.

Should you ever find yourself in a similar situation, I strongly recommend the exhaustive testing approach. You will be stunned what crap you find in your seemingly-simple code for handling dates. This also really solidified my view on the utility of automated/unit testing. You simply can not manually test a 731-element matrix, and I was getting an incredibly rich array of varying failures across that matrix, in billing code, which is very important code.

[1]: This is many years ago, before there were so many great billing services off the shelf available, and we still had a significant challenge to be able to take payments at all. And lest I unhumbly make myself sound wiser than I was/am, I learned a lot about what code is and isn't worth writing at that startup... the hard way. Mercifully I don't feel my gross errors really contributed to the failure in the end... the startup died of one-more-feature-before-we-can-release-itis: https://news.ycombinator.com/item?id=9640335
Wait. Didn't VICE do an excellent expose on this very topic, relief capitalism? edit: they call it disaster capitalism, but relief capitalism is also a real thing.

Pretty sure it's not the full episode, but this is a summary of the episode. https://www.youtube.com/watch?v=BNM4kEUEcp8

America's dirty little secret is that the majority of our "aid" is really not aid at all an not really meant for aiding and assisting. This is not really a new thing. It's actually a very old and disastrous thing.
TL;DR (the informational bits):

> First the Red Cross took a customary administrative cut, then the charities that received the money took their own fees. And then, according to the Red Cross' records, the charity took out an additional amount to pay for what it calls the "program costs incurred in managing" these third-party projects.

> In one of the programs reviewed by NPR and ProPublica, these costs ate up a third of the money that was supposed to help Haitians.

[...]

> said that a fifth of the money the charity raised would go to "provide tens of thousands of people with permanent homes ... where we develop brand-new communities ... including water and sanitation."

> The charity built six permanent homes and, according to their own account, no new communities.

[...]

> the project manager [...] was entitled to allowances for housing, food and other expenses, home leave trips, R&R four times a year, and relocation expenses. In all, including salary, it added up to $140,000.

---

These are the only factual bits I can find. I'm not saying the rest is untrue, but they include statements from locals who "cannot see that $24 million has been spent here," whatever that means.

Another example is where it says "first, the plan was to build houses," then going on to describe that people are still living in tents. But how many people live in tents? What percentage? How many houses were actually built? Or did they build 10 villas and leave the rest in tents? There is no real information that I can find.

A bit further on, it does include this:

> The original plan was to build 700 new homes with living rooms and bathrooms. The Red Cross says it ran into problems acquiring land rights.

... so then out of the 700, how many were built? It doesn't say anything about that.
New blood test could reveal every virus that's ever infected you
And as one shopkeeper explained it, offering change in a tray feels more polite than simply placing money in a customer’s hand.

See also English Victorian change packets:

http://boingboing.net/2012/04/30/victorian-change-packets-li...
You can take a hash, delete the file, and record the deletion. You'll use less space, know something is missing, and even be able to identify the deleted file if you encounter it again.
FWIW, they have something of a history if I recall; i only recently found out a few days ago, really.
can't tell if this is brilliant sarcasm
> The American Red Cross says it "provided homes" for more than 130,000 Haitians, but acknowledges that much of that is made up of people who went to a training seminar on how to fix their homes, received temporary rental help or lived in shelters like these in Bon Repos, which start to disintegrate after three to five years. Residents say they
don't have bathrooms, kitchens or running water.

I think the 130k people number is a big fat lie.
That's interesting because if I understand the bug correctly, it should have failed as soon as you performed the test less than 5 days before the end of the current month. (Except in December and July for which the next month has the same number of days in it.).
We use this at the (very large) corp that I work at, with very large, complex, high-traffic/revenue sites. Each component in the architecture has it's own "light/dark" deployment (in each environment), so any piece can be staged/tested/deployed/rolled-back with zero downtime. It has worked fairly well, with the majority of hiccups occuring during the ramp-up on the process.
In Messi's case this is exactly why it's the supreme advantage. He already possess world class skill and intelligence, add HGH to the mix to boost his athleticism and you have a balanced, top tier athlete.
We can have human language translated code
Hi,

I was thinking about that. We can have programming language transl files with translation for all the keywords in different languages. Then we can automatically show code with english/french etc keywords. Do you think that's tecnically feasible?
Actually a lot of us buy Apple for the hardware performance, just not the kind of performance you measure in GigaWhatevers :) A touchpad that's not horrific, great battery life, a quality screen, and managing to fit it all into a smaller/lighter package than anyone else are all high on my performance list. A few years ago I was looking for basically an ubuntu macbook air. Hardly anything even came close to an air & what did was generally still inferior and just as expensive.
Another possibility is that two activation patterns are so similar that they interfere and thus they merge, one replaces the other or they both become useless noise. See also: https://en.wikipedia.org/wiki/Forgetting#Interference_theori...
Just like your mobile.. http://www.osnews.com/story/27416/The_second_operating_syste...
> It was very simple things like severance if you get fired, things like having clearer salary minimums for each position, a clearer way to talk about raises, promotions

That's what employers should pay attention to. It seems like simple stuff that every employer should already have.
Red Cross is notoriously corrupt, yet after every disaster they get so much free publicity.
Why would it be a loss, then? People using Apple Pay were probably paying with a card previously, not cash. Transaction fees remain the same, POS remains the same if it already supported RFID cards, interface remains the same.
Cash also offers a level of freedom not offered by electronic payments, something that I think our future selves will learn to appreciate.
Can $2,000 build a whole house? Even in Haiti? I would think 10x that for anything we would call a "house". Its not surprising there is a vast unmet need in Haiti given its poverty and the scale of the disaster.
Invert your categorization direction. (same as SD cards, Class 10 > Class 8...)
Does anyone know anything about the effectiveness of other Haiti efforts like Mercy Corps?
I believe the reason is because all those paypoints have to be upgraded to handle Chiped cards by the beginning of next year. Why lose 3 month's profit when in 6 month's time, the same result will happen.

At least, I don't think there are many modern paypoints that don't allow for NFC payment.

edit: http://blogs.wsj.com/corporate-intelligence/2014/02/06/octob...

Of course this article is old and I don't know if there'll be some sort of, "Wait, wait no!", moment or something.
And arguably worse -- a product is a developed idea.
Oh, I don't know. They could just take some aggregate standard benchmark, and coerce it down to an integer. Have higher numbers be strictly better. Sure, you might get box makers trying to game it, but it would still be better than "here's some specs, you figure it out".

After a recent review of low-end (well, compared to an i7) AMD apus paired with high-end gpus[1], I'm not even sure most "professionals" can get anything meaningful out of specs alone. Sure an i7 with ddr4 is "better" than a dual-core AMD APU -- but if your target is 1080p gaming, it might not be much of a difference -- given the same GPU.

So it shouldn't be that hard make the statement "runs on Steambox rated 24 or higher" be true for all generations of steamboxes. Even when that'll have to be changed from 24 to 24000.

[1] http://www.anandtech.com/show/9307/the-kaveri-refresh-godava...
> The article states it perfectly at the end though: "When doing math that deals with time, specifically different units of time, it can lead to unexpected results if you are not careful with the ordering". I think this can generally be extended to "when doing any math that deals with time, it can lead to unexpected results if you are not careful with everything"!

Another idea: don't dress up things that don't have anything to do with conventional math as conventional math. Using operands who's value depends on the value of the expression evaluation up to this point (I'm guessing left to right) is an aberration.
Another way to do this is to specify the protocol in protobuf but have the server translate responses and requests to and from json. The java protobuf library does that for you out of the box. This is easier to implement. I would be curious to compare performance of both approaches in different contexts.
> the Red Cross provides almost zero information about how it spends its money.

If that is true, how can Charity Navigator rate it 80.5/100?

http://www.charitynavigator.org/index.cfm?bay=search.summary...
MERS spreading in S. Korea; probably Not a pandemic threat
Autopsy – A Colleaction of Lessons from Failed Startups
Strange. His political blog has been inactive for over a year.
> you only tell the subset of third parties between you and the cache.

That's not a privacy win at all if you want privacy from the cache, if you don't trust the cache, if the cache is wholly owned or used by you alone.

Even if all of that doesn't apply, you don't even have a guarantee that it will hit the cache. If it is a cache miss, no “privacy win”.

How many asterisks does this claim of a privacy win need before it should no longer be considered valid?

> At a cost of message confidentiality, of course, but if your message content doesn't need to be confidential (i.e. you're just GETing a resource), it's not a big loss.

You are forgetting the loss of message integrity, as well. That is a big loss.
This is one in a series of investigative stories conducted by ProPublica and NPR (disclosure: I used to work at PP but not on this project):

http://www.propublica.org/series/red-cross

Red Cross has made responses; I haven't read all the stories but my impression has been is that they haven't been on-point rebuttals:

Red Cross Demands Corrections to Our "Misleading" Coverage. Here's Our Response - http://www.propublica.org/article/red-cross-demands-correcti...

The project began last October: The Red Cross' Secret Disaster, which examined their aid after Hurricane Sandy: http://www.propublica.org/article/the-red-cross-secret-disas...
And surviving three weeks of racing, often over very difficult terrain.

Your "average" pro cyclist (the domestiques) dope because that's the only way get through a grand tour. It's not about going faster, it's about survival.
Not a chance. That is who they are. The only good site in the Gawker network is Lifehacker. At least they still remain objective, to say nothing about Deadspin and Jezebel.

I personally hope unionizing accelerates their decline into insolvency.
What a great write up! It's so refreshing to see people not succumbing to the life of fear that is pushed upon us so heavily by all aspects of modern society.
I guess "misleading operator overloading" would be too boring, huh.
Heck, moderate anything would be a good place to start.

Even the Democrats are right-wing extremists by European standards.
Not really. If you're looking for home security, get a terrier. They are high on loyalty and low on fear, so if they are barking, there's probably a non-packmate animal around. Some were bred to chase badgers down into their holes and kill them, after all. They're anything but timid.

Pit Bulls are terriers, and one reason they are so popular for lower-income city-dwellers is the manageable danger they present to unauthorized, non-packmate intruders in their range. You do not burgle a house with a Pit Bull or Staffordshire in it, period. And you think twice or thrice for any other type of dog. The fences, warning signs, food, vets, and boarding are very often cheaper in the long run than professional alarm system monitoring or contents replacement insurance.
Yes, temporarily at least. Flood someone with information and they will stop to make sense of the information they already have.
Bashing non-COMPACT storage is nonsense.

non-COMPACT store by itself doesn't add any significant overhead (only 2 bytes per cell and even less after compressed). What really wastes space is using collections types. Even using that I doubt it will ever reach the 30x mark the author stated.
If you went by CharityNavigator data, you'd think the American Red Cross was one of the well run ones.
Yes. Especially if you're using one of the systems as a failover or you're running them as a normally active-active configuration. You want DB replication, but you also want to be able to take down a blue or green, apply DB updates, be able to independently access blue or green to check out your changes, then roll the world over the upgrade leg, then do the same work on the other side, check it out, and then make it available.

Alternating on blue / green as the 'live' side works, too.
> Or did they build 10 villas and leave the rest in tents?

I think they did build 10 villas, just not in Haiti. It's very sad to read all of this. (great TL;DR by the way, thank you).
I'm not saying I have a better solution, but that seems overly complicated and manual (e.g. remembering that in two deploys we're deleting ColumnA and TriggerColAColB) for a system that is seemingly designed to help automate the deployment process.
Angel Investors Are Still the Lifeblood of Startups
Remote UI/UX jobs that are more intriguing than Caitlyn Jenner
If you had $500M, the best move for the community would be to create a Hati community long term investment of 100M. The community gets the dividends/interest from the investments. Long term sustainability is automatically achieved. That's free money over the long term for clean water projects, community buildings, etc.

Did Red Cross do that? Nope, people got tents and pocketed the rest.
> http://www.ietf.org/mail-archive/web/ietf/current/msg93416.h...

This post seems like reasonable criticism to me. It doesn't attack any individual.

It's fair to attribute motive for a particular agenda. The discussion would not be complete without considering conflict-of-interest motivations of the participants.

It also seems fair to say that Google and other companies with the goal of Internet centralization have been pushing this, and that this is one of the likely motivations for them.

It also seems fair to point out, in a technical way, that HTTPS-everywhere is not capable of achieving the goals that its proponents claim it will, and that it is more likely to be harmful to those goals.

The last sentence that you quote is perhaps unhelpful but the "rough consensus" decision-making model of the IETF creates a perfect situation for lobbyists from large companies to control the agenda. This can be seen as an abuse.

Edited to add: I would be very concerned if the chair of the IETF was seeking to quash discussion of this type. That would only prove there is a serious problem.
But then at least we know you're guilty if you use encryption.

It's kinda like the reasoning that banning marijuana was better for the police because they didn't need to distinguish between illegal drug use and legal drug use.
The Kindergarten Class in the Forest
Who exactly is a Tanzanian were questions that were also asks also when a Tanzanian of indian descent[1] represented Tanzania in international beauty pageants.

[1] http://en.wikipedia.org/wiki/Richa_Adhia
I was expecting a september release, but:
"What's strange about the Economic Daily News' report, however, is that it says the new 4-inch iPhone is expected to ship in the first quarter of next year — not later this year in September when Apple usually unveils its new iPhones."
It's not at all easier, that's why workers want to unionize in the first place. US companies are afraid of unions because the power accumulated by the union makes it harder for the company to deal with workers.
It would be interesting to compare this with the improvement that he would have got if he did altitude training.
Our R&D Team's Research into Staggered Spinup and Its Effect on Power Draw
From my memory, they had a reputation for bait and switch - raising money during a disaster, but spending it elsewhere. I think they cleaned that up, including a change in leadership.

This article is new in claiming innefectiveness at usefully spending money to help disaster victims. I would love to see a detailed audit.
Have you tried adding the card to passbook? There are a number of websites that let you generate a passbook card for an arbitrary barcode/qr
Thank you for this comment! that certainly sounds like a nightmare of edgecases. The first of the month certainly seems like the better way to go!

This was sorta like that - specs would fail some days, but not others. The code worked, but the tests failed seemingly randomly.
> What platforms do we need to get rid of to get rid of autoconf/automake/configure and use e.g. CMake instead?

Why would you want that? Autotools is the devil we know. CMake has its own problems and from a statistical sample of one project implementing both, I came to the conclusion that CMake is more frustrating than Autotools when you need to do something unusual.
We need totally transparent charities across the globe. A lot of my friend here in US prefer to support small local charities that they exactly know how money are going to be spent, even more, they can donate time and participate in those activities. Unfortunately for the charities of a large scale other concerns comes to play, especially here in US - taxes.
Tales of a Part-Time Sysadmin: Dogfooding Docker to Test Docker
Rape is not endemic in the UK prison system, certainly not to the same degree as in the US.

Source: My wife's uncle that was a prison warder in Belmarsh, and people I have know who have been to prison.
So does this effectively mean - only create tables and add columns in your db schema migrations (no updating and removing)?
That, and the incompetence they have in spending it. I will not donate to red cross disaster relief again.
I agree, in fact the author seemed to go out of their way to explain everything.
Thanks, I misread the comment.
A related one which I found is A + B - B != A

In pretty much the same case, where A==some time and B == 1 month

This came up in calculations for monthly subscriptions, trying to reach back in time to work out pro-rata charges for changing subscription details part way through a month.
Surger, a CLI, wifi gps powered, “surge pricing” indicator for Uber
I think the other issue which is buried in the article is they couldn't get the rights to build on the land. That still begs the question of where all the money went but sounds like there is enough blame to go around.
The POS does not need to be compatible. The card reader alone does. The relatively high end Verifone VX 680 devices (which are the most popular in the UK from what I can tell), cost about $300 each. Really not that much.
>>I think some people get so combative because their identity is wrapped up in being right. It's unfortunate, given our capacity to collaborate and build, that we still struggle with these scuffs.

Unfortunately, that is very typical of Western (USA/Europe) nerds as they always claim to be right. I cannot make that claim for nerds of Asia.
zlib latest takes 3 seconds, zlib-ng takes 13 seconds

alex@martha:~/src/zlib$ du -sh $TESTFILE
197M	/home/alex/src/enwiki-20141106-pages-articles-multistream-index.txt.gz
alex@martha:~/src/zlib$ LD_LIBRARY_PATH=./ time ./minigzip -d <$TESTFILE >/dev/null
3.36user 0.03system 0:03.87elapsed 87%CPU (0avgtext+0avgdata 1632maxresident)k
8inputs+0outputs (0major+90minor)pagefaults 0swaps
alex@martha:~/src/zlib$ LD_LIBRARY_PATH=./ time ./minigzip -d <$TESTFILE >/dev/null
3.34user 0.04system 0:03.76elapsed 90%CPU (0avgtext+0avgdata 1704maxresident)k
0inputs+0outputs (0major+91minor)pagefaults 0swaps
alex@martha:~/src/zlib$ cd ../zlib-ng/
alex@martha:~/src/zlib-ng$ LD_LIBRARY_PATH=./ time ./minigzip -d <$TESTFILE >/dev/null
12.20user 0.04system 0:13.63elapsed 89%CPU (0avgtext+0avgdata 1576maxresident)k
264inputs+0outputs (1major+86minor)pagefaults 0swaps
alex@martha:~/src/zlib-ng$ LD_LIBRARY_PATH=./ time ./minigzip -d <$TESTFILE >/dev/null
12.15user 0.08system 0:13.58elapsed 90%CPU (0avgtext+0avgdata 1428maxresident)k
0inputs+0outputs (0major+84minor)pagefaults 0swaps
Insurance underwriting and fraud analysis.
They also offer a hail sensor.
Cards have big fees attached, so many smaller retailers insist on cash so they don't lose 3% of their income. Even at small, local places that do take cards, I try to always pay in cash to help support them.
Is this actually proven? Pi is irrational, but is it proven to be random (or normal)?

http://www.askamathematician.com/2009/11/since-pi-is-infinit...

Also, assuming that it is, if 'start as position X and read Y bits from pi' produced an illegal image (top secret document, abuse images, etc), what would be the legality of trading such information?