Live data from Hacker News

Programmer interrupted: The cost of interruption and context switching (2022)

contextkeeper.io

51–60 of 271 posts

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#52

[flagged]

>why would I hire a programmer and pay them 200k a year when they cannot handle basic communication without becoming unproductive?

As entrepreneur myself, the main reason I pay someone 200K is because I can make this person generate more than 200k in profit.

The fact that someone have flaws, like any human being has, is an opportunity for me as I can make those flaws irrelevant by providing the environment where a team could be extra productive.

That means the team needs me and my company. If they were perfect on their own, they would not need me or my company at all and would be able to compete with my company.

If robots could one day do the work of programmers, they would be able to do the work of managers and entrepreneurs as well, which is way easier(I am engineer too).

>Are humans still necessary when robots are able to understand humans and become fluent ESLs?

Yes, they are.

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#53
post #18

Earlier quoted context omitted.

Its especially helpful for stuff where I haven't touched it in a while too. One alias and boom, I'm back in a session with a pane with my editor open, a pane with the log, a pane with some notes, and a pane with the shell displaying the last line of code I ran from when I was last working on this pet project over six months ago. Right where I left everything and I can jump back in as if I was working on it an hour ag…

I have a separate VS Code window connected to a dev container for each project that stays open for days, weeks or months at a time. Does the tmux approach materially improve upon that setup? Genuinely curious if I’m missing out on something here.

You can end up pretty deep down the rabbit hole with tmux and configuring it in different ways. One thing you can do that you might not be able to do with your vscode set up is have a script, written in tmux commands, that generates a complicated windowing environment. I am not familiar with the capabilities of your setup though, since I don't use vscode. I would guess tmux is more comfortable than vscode for using it with just the keyboard too.

There's a ton written on tmux as you can imagine by this point. This page seems pretty comprehensive on the advanced features including tmux scripting:

https://github.com/tmux/tmux/wiki/Advanced-Use

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#54

Earlier quoted context omitted.

I have a separate VS Code window connected to a dev container for each project that stays open for days, weeks or months at a time. Does the tmux approach materially improve upon that setup? Genuinely curious if I’m missing out on something here.

Maybe, you can SSH to GNU Screen and attach where you were, perhaps from your phone to just read. You could do the same with rdesktop to something x11, but you'd need more than a 256MB VM for that. If you have this running 24x365 then you'd spend more energy/money.

To all above: but machines reboot, also, not? Even our coorp Linuxes now succumb to ugly IT update reboot cycles, Cloud VMs even more ephemeral, and lets not even start with dev containers... One can script tmux sessions to some degree, but still loosing a lot of state (editor open ther, shell history here..).

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#55

I actively like being distracted when I'm programming. I tend to approach a problem from lots of different directions, each time fizzling out, hitting a block or having some sort of mental reset, until something unconsciously clicks and an overall structure, understanding or solution emerges. Continually leaving and returning to the problem is a part of that process, so I tend to find someone walking up with a questi…

Indeed, this seems unusual in programmer land. As evidence we have a thread like the current one reaching the front page several times a day. But your way is also my way. I am active in a very wide array of topics, and happy to flit between them. Sometimes I dive deep, but it's usually in a critical moment of synthesis when ideas developed over months or years come to clarity and I put them to action. This is working…

> It is sad to see how many people are made uncomfortable by interruption. It's the stuff of life, social life at least

A key concept from the book "A Mind for Numbers" is the difference between "focus mode" and "diffuse mode" thinking.

Focus mode is essentially a concentrated flow state and diffuse mode is a relaxed state, open to distraction and creativity.

Both modes are necessary for effective problem solving but my issue is an abundance of distractions which keep most of us stuck in the diffuse state and no time in the focused state.

> And in terms of getting into flow state, for me it is always basically instantaneous. The flow is just sitting there under a few seconds of pause.

Rare, for most people it takes 20 minutes. If I get equally spaced out distracting emails I will spend no time in the flow state at all.

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#57
post #25

Sadly, the cost of context switching is well-known, and has been proven, over and over again, for decades. But managers don't care (and many co-workers also). A quick shufti at most modern open-plan offices, shows the contempt that managers have for developer context. They know better, and have made the conscious decision to go open, anyway. I remember visiting the Facebook/Instagram building, in NYC, and was aghast…

>But managers don't care (and many co-workers also). i bet 99% of time people are interrupting themselves. Like i just did to browse HN.

> i bet 99% of time people are interrupting themselves. Like i just did to browse HN.

I don't know about you but I am here on a pomodoro break between two tasks.

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#58

Earlier quoted context omitted.

Same with SQL, which was promised as a way for data processing managers to get rid of expensive programmers as the managers would now be able to get whatever information they wanted from their databases using an easy to understand, English like language. All it did was change the nature of the job of retrieving and storing database information but didn't actually get rid of the programmers.

> All it did was change the nature of the job It also created SQL injection vulnerabilities, so there's that.

No, that’s something bad programming languages did.

SQL is purely declarative.

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#59
post #13

At a job I had they wanted me to install an instant messaging app on my compute! I refused point blank. I said they could email me and I'd look at he email every so often. If it was really important they could get up and walk to see me. If it wasn't important enough for others to walk then it definitely wasn't important enough to interrupt me. Before that I was at a place where they had tannoys. I moved the tannoys a…

I would not hire you if you refused to use instant messaging (my enterprise uses Slack and gChat). You would be unable to do the job- you wouldn't be able to contribute to decision making, or would miss out on all sort of information. We (our department) has moved out of email with the exception of formal requests and things that cost more than a few tens of thousands of dollars.

Would you use IRC? That's all slack really is.

Re: Programmer interrupted: The cost of interruption and context switching (2022)

#60
My company likes to schedule at least 20 hours of meetings spread across the week in such a way that you rarely get more than 30 minutes in between two. Then management wonders why it takes so long to get anything done. Guess its a mystery. Let’s schedule a recurring meeting to discuss it…
Post reply on HN