> Which was what the setting value was changed to in the patch that was eventually accepted. This means that setting help.autocorrect to 1 logically means "wait 100ms (1 decisecond) before continuing". The mistake was here. Instead of retargeting the existing setting for a different meaning, they should have added a new setting. help.autocorrect - enable or disable help.autocorrect.milliseconds - how long to wait The…
Why is Git Autocorrect too fast for Formula One drivers?
81–90 of 248 posts
Re: Why is Git Autocorrect too fast for Formula One drivers?
#82Earlier quoted context omitted.
I think if it's spring-loaded then definitely. (But it's 100ms, not 10ms.)
Assuming the best case scenario of feeling the slap in 90ms, it would leave 10ms to abort the command. Or did the 90-180ms range refer to something else?
Re: Why is Git Autocorrect too fast for Formula One drivers?
#83Pet peeve: Timespan configs that don't include the unit in the variable name. I'm so sick of commands with --timeout params where I'm left guessing if it's seconds or millis or what.
Re: Why is Git Autocorrect too fast for Formula One drivers?
#84> Which was what the setting value was changed to in the patch that was eventually accepted. This means that setting help.autocorrect to 1 logically means "wait 100ms (1 decisecond) before continuing". The mistake was here. Instead of retargeting the existing setting for a different meaning, they should have added a new setting. help.autocorrect - enable or disable help.autocorrect.milliseconds - how long to wait The…
The “real” issue is an untyped configuration language which tries to guess at what you actually meant by 1. They’re tripling down on this by making 1 a Boolean true but other integers be deciseconds. This is the same questionable logic behind YAML’s infamous “no” == false.
Re: Why is Git Autocorrect too fast for Formula One drivers?
#85Earlier quoted context omitted.
In this case the reaction starts before you hit enter, as you're typing the command So, you type `git pshu ` and realise you made a typo before you've finished typing. You can't react fast enough to stop hitting enter but you can absolutely ctrl+c before 100 more ms are up
I'm still pretty skeptical of this claim. If you type 60 wpm, which is faster than an average human, but regular for people who type as professionals, you spend on average 200ms on a keystroke. 60 standard words per minute means 300 chars per minute [0], so 5 chars per second which is 200ms per char. Many people type faster than this, yes, but it's all still very much pushing it just to even meet the 100ms limit, and…
I'm not a competitive speed typist or anything but I struggle to get above 110 on a standard keyboard and I don't think I've ever seen anyone above the 125-130 range.
[0] https://www.typingpal.com/en/documentation/school-edition/pe...
Re: Why is Git Autocorrect too fast for Formula One drivers?
#86One day it'll dump the recent bash and git history into an LLM that will say something along the lines of "alright dumbass here's what you actually need to run"
Re: Why is Git Autocorrect too fast for Formula One drivers?
#87I think it makes sense, if I typed something wrong, I often feel it before I can read it, but if I already pushed enter, being able to ctrl+c within 100 ms is enough to save me. I'm pretty sure I've also aborted git pushes before they touched anything before I put this on, but this makes it more reliable.
Re: Why is Git Autocorrect too fast for Formula One drivers?
#88That aside, I feel the reason is to advertise the feature so that the user gets a chance to set the timer up to his preference or disable autocorrect entirely.
Re: Why is Git Autocorrect too fast for Formula One drivers?
#89If the original setting had been named something bool-y like `help.autocorrect_enabled`, then the request to accept an int (deciseconds) would've made no sense. Another setting `help.autocorrect_accept_after_dsec` would've been required. And `dsec` is so oddball that anyone who uses it would've had to look up.
I insist on this all the time in code reviews. Variables must have units in their names if there's any ambiguity. For example, `int timeout` becomes `int timeout_msec`.
This is 100x more important when naming settings, because they're part of your public interface and you can't ever change them.