Earlier quoted context omitted.
I've only been in the job field for six years, and yet: My first boss accidentally deleted our QA database, meaning to delete a local copy A later boss accidentally deleted our production database, thinking it was the clone that he had just made (which luckily we still had) Both of them were very experienced developers in their 40s. Nobody is beyond this kind of mistake.
Ironically there seems to be no time more prone to these kinds of mistakes than when you're trying to prevent or fix them.
Type in the exact number of machines to proceed
221–230 of 340 posts
Re: Type in the exact number of machines to proceed
#222I've seen this called "pointing and calling" [1], Japan's train drivers use the technique to force themselves to perform actions and take notice of the current environment. I personally took it to heart, it's a good system for forcing a cache miss in the brain - make sure you're on "database production" or "database localhost" etc. [1] https://en.wikipedia.org/wiki/Pointing_and_calling
I've only been in the job field for six years, and yet: My first boss accidentally deleted our QA database, meaning to delete a local copy A later boss accidentally deleted our production database, thinking it was the clone that he had just made (which luckily we still had) Both of them were very experienced developers in their 40s. Nobody is beyond this kind of mistake.
Re: Type in the exact number of machines to proceed
#223Earlier quoted context omitted.
I wish SQL had a dry-run mode in updates and deletes for that reason. "Run it as a query first" gets 90% of the way until you drop a constraint by accident whilst rewriting it as an update :o
I think an improvement to SQL would be for insert/update/delete clauses to require a where clause and allow for something like 1=1 if you really intend to hit all rows. A safe but even more invasive would be requiring an end to the were clause as well (to prevent selecting a few but not all constraints).
Re: Type in the exact number of machines to proceed
#224Earlier quoted context omitted.
If you really think that’s an issue, pasting could be disabled for that input field. Would that make you happier? It hasn’t been an issue for me, since repo names aren’t usually super long and onerous to type.
> If you really think that’s an issue, pasting could be disabled for that input field. Would that make you happier? many (most?) HN users probably have that disabled, because too many sites abuse it to block password managers, for "security reasons" .
The point I was making is that copying and pasting seems like more effort than just typing the repo name. Do you commonly encounter long, inscrutable repo names? Do you delete repos frequently enough to have built up the habit of copying and pasting the repo name into the delete box?
If it is common enough, disabling paste would actually benefit the user based on the premise of the article.
Re: Type in the exact number of machines to proceed
#225Earlier quoted context omitted.
I learned a technique from a gray beard[0] when I worked as a student sys admin for the CS dept over two decades ago. Whenever typing a destructive command, he'd take his hands off the keyboard and drop them to his side, re-read the command, then put his hands back to press enter. I do this whenever I'm on a production server (which is rare anyway). I use different colored prompts for local and remote shells. [0] Tec…
Different-colored prompts for different machines is a great thing to do (I've been doing it for years), and very easy to implement
Re: Type in the exact number of machines to proceed
#226So, related obviously correct designs: 1. Git's Force-with-lease. Git push's "force" is too powerful, you will likely regret this much power, but it's tempting. So force-with-lease is the same power but conditional on you telling git what exactly the state was that you're overriding. This has two benefits, one is like Rachel's, it is an opportunity for a human to stop for a moment and consider, wait, why are we overr…
(I realize there is a possible error message case if the remote has changed... but I don’t feel like this command is the best one to use to discover whether the remote has changed, if you have no changes you actually intend to force push.)
Re: Type in the exact number of machines to proceed
#227I've seen this called "pointing and calling" [1], Japan's train drivers use the technique to force themselves to perform actions and take notice of the current environment. I personally took it to heart, it's a good system for forcing a cache miss in the brain - make sure you're on "database production" or "database localhost" etc. [1] https://en.wikipedia.org/wiki/Pointing_and_calling
The knobs are labeled with a terrible little glyph meant to indicate which is which, and I've supplemented this with plain-english Brady labels "front left", "front right", etc. Now I speak the words above the knob, and point to the burner. It felt goofy at first, but now it feels normal, and like I'm tempting fate if I skip it.
Re: Type in the exact number of machines to proceed
#228Earlier quoted context omitted.
Ironically there seems to be no time more prone to these kinds of mistakes than when you're trying to prevent or fix them.
Most of the worst production issues I've been involved with have come from trying to fix a minor issue and then somebody making a mistake. The way our brains are wired to handle stress isn't really useful for debugging complicated problems.
First, calm down.
I’m still amazed that he could be so calm when I’d just deleted a bunch of stuff on a clients production environment.
May not have been the most lucrative company I’ve ever worked for, but it was definitely the best one.
Re: Type in the exact number of machines to proceed
#229Earlier quoted context omitted.
I've never understood this idea. If you believe we should never use nuclear weapons, then don't have them at all. If you believe there is a case where it may be moral and rational to use nuclear weapons, why would you want to put a potential barrier in the way of their use? You could have a situation where everyone was agreed to use them but the president was physically unable to harm the aide to use them. You can kn…
You put too much confidence in human reason. Everybody agrees that this is a nuke-them-all situation, but the president, given himself part of the task of ripping apart human bodies, thinks more about the subject and decides a another diplomatic round is a better option.
From the perspective of an advocate I'd say: If they can't come to terms with killing one, who are they to execute hundreds of thousands?
Re: Type in the exact number of machines to proceed
#230> 1221425541 machines will be affected "Do you care? (Y/N)" Cattle, people. Not pets. Just make sure you don't hit all machines simultaneously and are rolling, instead. Since the post is talking about automation anyway, assume that any machine that can go down will go down. Ensure that any such disruption will be minimal. Oops, you just killed the production database? Whatever, who cares, it has just failed over anyw…