A single line of code cost $8000

301 lordfuckleroy 407 4/29/2025, 5:40:35 AM pietrasiak.com ↗

Comments (407)

mieko · 2d ago
For people finding this thread via web search in the future:

screen.studio is macOS screen recording software that checks for updates every five minutes. Somehow, that alone is NOT the bug described in this post. The /other/ bug described in this blog is: their software also downloaded a 250MB update file every five minutes.

The software developers there consider all of this normal except the actual download, which cost them $8000 in bandwidth fees.

To re-cap: Screen recording software. Checks for updates every five (5) minutes. That's 12 times an hour.

I choose software based on how much I trust the judgement of the developers. Please consider if this feels like reasonable judgement to you.

ryandrake · 2d ago
Yea, it seems like the wrong lesson was learned here: It should have been "Don't abuse your users' computers," but instead it was, "When you abuse your users' computers, make sure it doesn't cost the company anything."
infogulch · 1d ago
That's a good summary and explains many ills in the software engineering industry.
ljm · 1d ago
$8000 for 2 petabytes of traffic is pretty cheap for them also.

There are plenty of shitty ISPs out there who would charge $$ per gigabyte after you hit a relatively small monthly cap. Even worse if you're using a mobile hotspot.

I would be mortified if my bug cost someone a few hundred bucks in overages overnight.

aidenn0 · 1d ago
It got one of their customers booted off of their ISP; they did cover that person's overage costs though (and hopefully that person could get their account back).
benwilber0 · 2d ago
> their software also downloaded a 250MB update file every five minutes

How on earth is a screen recording app 250 megabytes

pixl97 · 2d ago
Because developers can suck.

I work with developers in SCA/SBOM and there are countless devs that seem to work by #include 'everything'. You see crap where they include a misspelled package name and then they fix it by including the right package but not removing the wrong one!.

PeeMcGee · 1d ago
The lack of dependency awareness drives me insane. Someone imports a single method from the wrong package, which snowballs into the blind leading the blind and pinning transitive dependencies in order to deliver quick "fixes" for things we don't even use or need, which ultimately becomes 100 different kinds of nightmare that stifle any hope of agility.
xxr · 1d ago
In a code review a couple of years ago, I had to say "no" to a dev casually including pandas (and in turn numpy) for a one-liner convenience function in a Django web app that has no involvement with any number crunching whatsoever.
whstl · 1d ago
Coincidentally, Copilot has been incredibly liberal lately with its suggestions of including Pandas or Numpy in a tiny non-AI Flask app, even for simple things. I expect things to get worse.
hooverd · 1d ago
There's a ton you can do with sqlite, which is in the Python standard library. You just have to think about it and write some SQL instead of having a nice Pythonic interface.
thornewolf · 1d ago
To push back on this, I consider pandas/numpy so crucial to Python as a whole they are effectively stdlib to me. I wouldn't blink at this because it would happen sooner or later.

Unless is was absolutely critical the server have as small as a footprint as humanly possible and it was absolutely guaranteed there would never need to be included in the future of course. However, that first constraint is the main one.

goodpoint · 1d ago
You forgot the "/s"?
_tom_ · 1d ago
Automated dependency resolution has made it so the default is frequently

> Someone imports a single method from the RIGHT package

and hundreds of megabytes come in for what might be one simple function.

jofla_net · 1d ago
and when that fails #pragma once, oh the memories!
AndrewStephens · 1d ago
>> their software also downloaded a 250MB update file every five minutes

> How on earth is a screen recording app 250 megabytes

How on earth is a screen recording app on a OS where the API to record the screen is built directly into the OS 250 megabytes?

It is extremely irresponsible to assume that your customers have infinite cheap bandwidth. In a previous life I worked with customers with remote sites (think mines or oil rigs in the middle of nowhere) where something like this would have cost them thousands of dollars per hour per computer per site.

esalman · 1d ago
> It is extremely irresponsible to assume that your customers have infinite cheap bandwidth

Judging by the price of monitor stands, I wouldn't be surprised for Apple to make such assumptions.

dchftcs · 1d ago
For a long time iOS did not have features to limit data usage on WiFi. They did introduce an option more recently for iPhone, but it seems such an option is not available to MacOS. Windows supported it as far as I could remember using it with tethering.
JCharante · 1d ago
screen studio is pretty great, it has a lot of features and includes a simple video editor
mobilemidget · 2d ago
Or.. Why on earth you need to check for updates 288x per day. It sounds and seems more like 'usage monitoring' rather than being sure that all users have the most recent bug fixes installed. What's wrong with checking for updates upon start once (and cache per day). What critical bugs or fixes could have been issued that warrant 288 update checks.
pcthrowaway · 1d ago
A 250MB download should be opt-in in the first place
hulitu · 1d ago
> A 250MB download should be opt-in in the first place

I've read on HN that a lot of people have 10Gb Ethernet at home. /s

mobilemidget · 1d ago
I got 8 :)
zoky · 1d ago
Do you mean 8 homes with 10Gb Ethernet, or 1 home with 8 10Gb Ethernet connections?
mobilemidget · 5h ago
8 of the 10 Gbits I meant :) sorry I see it reads a bit weird yes. So 8 gbit for single line is the max currently. But huge competition on the horizon, so I expect soon more :)
486sx33 · 1d ago
I read it as 1 x 8GB connection But that’s only because I think 8GB is offered in my area. I’ve limited my current service to 1.5GB / 1GB fibre, because well I only run gbit Ethernet … so more sounds totally unnecessary
jenadine · 1d ago
8 people who have 10Gb Ethernet at home
partdavid · 1d ago
It sounds right, and this is the kind of thing I'd expect if developers are baking configuration into their app distribution. Like, you'd want usage rules or tracking plugins to be timely, and they didn't figure out how to check and distribute configurations in that way without a new app build.
hulitu · 1d ago
> they didn't figure out how to check and distribute configurations in that way without a new app build.

Any effort to use their brain shall be drastically punished. /s

f1shy · 1d ago
What's wrong with checking for updates upon start once (and cache per day)

For me that would also be wrong, if I cannot disable it in the configuration. I do bot want to extend startup time.

dontlikeyoueith · 1d ago
Wait until you learn about non-blocking IO. And threads.

It's a whole new world out there.

tough · 1d ago
If you're expecting the guys shipping the 250mb bloated app to get this right i might haave a bridge to sell you
f1shy · 1d ago
Pretty snarky and useless comment. It is clear I mean also, for example, noot use BW for that.
absolutelastone · 1d ago
They probably just combined all phoning home information into one. Usage monitoring includes version used, which leads to automatic update when needed (or when bugged...).
js2 · 1d ago
Unpacked, it's actually 517M on disk:

   517M  ─┬ Screen Studio.app                     100%
   517M   └─┬ Contents                            100%
   284M     ├─┬ Resources                          55%
   150M     │ ├── app.asar                         29%
   133M     │ └─┬ app.asar.unpacked                26%
   117M     │   ├─┬ bin                            23%
    39M     │   │ ├── ffmpeg-darwin-arm64           8%
    26M     │   │ ├── deep-filter-arm64             5%
    11M     │   │ ├─┬ prod                          2%
  10.0M     │   │ │ └── polyrecorder-prod           2%
    11M     │   │ ├─┬ beta                          2%
  10.0M     │   │ │ └── polyrecorder-beta           2%
  10.0M     │   │ ├── hide-icons                    2%
   9.9M     │   │ ├─┬ discovery                     2%
   8.9M     │   │ │ └── polyrecorder                2%
   5.6M     │   │ └── macos-wallpaper               1%
    16M     │   └─┬ node_modules                    3%
    10M     │     ├─┬ hide-desktop-icons            2%
  10.0M     │     │ └─┬ scripts                     2%
  10.0M     │     │   └── HideIcons                 2%
   5.7M     │     └─┬ wallpaper                     1%
   5.7M     │       └─┬ source                      1%
   5.6M     │         └── macos-wallpaper           1%
   232M     └─┬ Frameworks                         45%
   231M       └─┬ Electron Framework.framework     45%
   231M         └─┬ Versions                       45%
   231M           └─┬ A                            45%
   147M             ├── Electron Framework         29%
    57M             ├─┬ Resources                  11%
  10.0M             │ ├── icudtl.dat                2%
   5.5M             │ └── resources.pak             1%
    24M             └─┬ Libraries                   5%
    15M               ├── libvk_swiftshader.dylib   3%
   6.8M               └── libGLESv2.dylib           1%
nativeit · 1d ago
Is it normal to include the Electron framework like that? Is it not also compiled with the binary? Might be a stupid question, I'm not a developer. Seems like a very, very heavy program to be doing such a straightforward function. On MacOS, I'm sure it also requires a lot of iffy permissions. I think I'd stick with the built-in screen recorder myself.
486sx33 · 1d ago
F** Electron
stevage · 1d ago
So looks like the app itself is about 10MB but there are multiple copies of it, a bundled ffmpeg and all kinds of crap like wallpaper?
js2 · 1d ago
I'm not sure why there are both app.asar and app.asar.unpacked. I did just run `npx @electron/asar extract app.asar` and confirmed it's a superset of app.asar.unpacked. The unpacked files are mostly executables, so it may have something to do with code signing requirements.
stevage · 1d ago
Looks like a one person shop, lots of things not optimised.
latexr · 1d ago
As I recall, it’s an Electron app. I just checked and the current version of Google Chrome is 635 MB, with its DMG being 224 MB.

So yes, it’s insane, but easy to see where the size comes from.

EasyMark · 1d ago
firefox is only about 200MB less.
latexr · 1d ago
“Only” is doing some heavy lifting there. 200 MB is a lot, both in absolute and relative terms. It means Firefox is a full third smaller.

Regardless, that’s absolutely irrelevant to the point that this app’s size is explained by Chromium’s (and thus Electron’s) size.

tough · 1d ago
Tauri has been a thing for a while, it baffles me people still choose Electron without a good reason to do so.

Also webapps are just great nowadays most OS support install PWA's fairly decently no?

ffs

nsingh2 · 1d ago
Tauri is not as platform-agnostic as Electron is because it uses different web views depending on the platform. I ran into a few SVG-related problems myself when trying it out for a bit.

For example, on Linux, it uses WebKitGTK as the browser engine, which doesn't render the same way Chrome does (which is the web view used on Windows), so multi-platform support is not totally seamless.

Using something like Servo as a lightweight, platform-independent web view seems like the way forward, but it's not ready yet.

bigiain · 1d ago
> Tauri is not as platform-agnostic as Electron

I suspect the real reason electron got used here is that ChatGPT/Copilot/whatever has almost no Tauri example code in the training set, so for some developers it effectively doesn't exist.

lvass · 1d ago
>on Linux it uses WebKitGTK

It's about time Linux desktops adopt some form of ${XDG_WEB_ENGINES:-/opt/web_engines} convention to have web-based programs to fetch their engines as needed and play nice with each other.

hulitu · 1d ago
It has: /dev/null /s
jenadine · 1d ago
We're talking about a MacOS App. Platform-agnostic is irrelevant.
nsingh2 · 1d ago
It's relevant in the broader context, cross-platform is a significant reason people choose Electron, and lighter alternatives like Tauri still have some issues there.
brooke2k · 1d ago
seconded -- tried to use tauri for a cross-platform app but the integrated webview on android is horrendous. had to rewrite basic things from scratch to work around those issues, at which point why am I even using a "cross-platform" framework?

I imagine if you stick to desktop the situation is less awful but still

Izkata · 1d ago
> Tauri is not as platform agnostic as Electron is

Found this a few months ago: https://gifcap.dev/

Screen recording straight from a regular browser window, though it creates GIFs instead of video files. Links to a git repo so you can set it up locally.

tough · 1d ago
Thanks, didn't knew about Servo, hopefully we'll get there Electron really is bloated and any app using it eats my ram whatever how much of it i have
ranger_danger · 1d ago
> Also webapps are just great nowadays most OS support install PWA's fairly decently no?

I would say no, and some are actively moving away from PWA support even if they had it before.

Plus, electron et al let you hook into native system APIs whereas a PWA cannot, AFAIK.

486sx33 · 1d ago
There’s never a good reason to chose electron.
ericmcer · 1d ago
The app itself is probably much bigger than 250mb. If it is using Electron and React/other JS library like a million other UIs just the dependencies will be almost that big.
hi_hi · 1d ago
For context, the latest iOS update is ~3.2GB, and the changelog highlights are basically 8 new emojis, some security updates, some bug fixes. It makes me want to cry.
jcgl · 1d ago
That 3.2G is some sort of compressed OS image though, right? So it’d be of a constant size relative to whatever changes or updates it brings.
aziaziazi · 1d ago
Just my hypothesis: some softwares includes video tutorial accessible offline. A short but not-compressed-high-res video can easily go big.
256_ · 1d ago
It was probably written by the type of programmers who criticise programmers like me for using "unsafe" languages.
rat9988 · 1d ago
You probably deserve to be criticized if you think this is the culprit.
asmor · 1d ago
"How can I make this about me and my C/C++ persecution complex?"
lawgimenez · 2d ago
I don’t use their software but if someone has they should be able to decompile it.
iends · 2d ago
It's an electron app.
ranger_danger · 1d ago
I would bet money it's electron
VWWHFSfQ · 2d ago
I would be so embarrassed about this bug that I would be terrified to write it up like this. Also admitting that your users were forced to download 10s or 100s of gigabytes of bogus updates nearly continuously. This is the kind of thing that a lot of people would just quietly fix. So kudos (I guess) to blogging about it.
zahlman · 1d ago
Not everyone even has an Internet connection that can reliably download 250MB in 5 minutes.

Yes, even in metropolitan areas in developed countries in 2025.

Hikikomori · 1d ago
Even doable on very long range ADSL, guess there are still some dialup users.
mlyle · 1d ago
That's 6.5 megabits/second, plus overhead. Many DSL circuits exceed this, but not all.
Retric · 1d ago
Most DSL I’ve seen has been way slower than 6.5 megabits/s. If you’re that close to infrastructure you can likely get cable etc.

1.5megabits/s is the still common, but Starlink is taking over.

zahlman · 1d ago
Not dialup. Just bad last-mile wiring, as far as I can tell.

Apparently such service is still somehow available; I found https://www.dialup4less.com with a web search. Sounds more like a novelty at this point. But "real" internet service still just doesn't work as well as it's supposed to in some places.

mr_toad · 1d ago
My current AirBnB has only cellular backed WiFi which would struggle to download 250MB at peak times.
ranger_danger · 1d ago
I struggle to get close to 6mbps on good days... some of us are still stuck on DSL monopolies.
f1shy · 1d ago
Germany?
zahlman · 1d ago
Canada. But yes, I've heard the stories about Germany, and Australia too.

In point of fact, I can fairly reliably download at that rate (for example I can usually watch streaming 1080p video with only occasional interruptions). The best case has been over 20Mbit/s. (This might also be partly due to my wifi; even with a "high gain" dongle I suspect the building construction, physical location of computer vs router etc. causes issues.)

outsidein · 1d ago
Microsoft InTune WUDO has a similar bug costing my department 40000 € internal charging per month for firewall log traffic of blocked tcp 7680 requests. 86000 requests per day per client, 160 million per day total. MS confirmed the bug but did nothing to fix it.
skirge · 1d ago
how? Do you investigate each blocked packet as separate alert?
outsidein · 1d ago
Yes, all packets get logged (metadata only). Otherwise we wouldn’t know there is an issue.

Those packets consume bandwidth and device utilization, too but this is flat fee, whereas log traffic is measured per GB so we investigated where an unexpected growth came from.

hulitu · 1d ago
> MS confirmed the bug but did nothing to fix it.

They are building features right now. There are a lot of bugs which Microsoft will never fix, or it fixes them after years. (Double click registered on mouse single clicks, clicking "x" to close the window, closes also the window underneat, GUI elements rendered as black due to monitor not recognized etc).

homebrewer · 1d ago
It's probably their way of tracking active users without telling you so, so it makes a lot of sense to "check for updates" as frequently as possible.
bredren · 1d ago
Little Snitch catches these update request checks and I realize now that it should have an additional rule meta which is *how often* this endpoint request should be allowed (LS should allow throttling not just yes / no)
tough · 1d ago
murus+snail?
arvindh-manian · 1d ago
Obviously five minutes is unnecessarily frequent, but one network request every five minutes doesn't sound that bad to me. Even if every app running on my computer did that, I'm not sure I'd notice.
alpaca128 · 1d ago
People complaining about 5 minute update checks hopefully don't use Windows 10/11.

A while ago I did some rough calculations with numbers Microsoft used to brag about their telemetry, and it came out to around 10+ datapoints collected per minute. But probably sent in a lower frequency.

I also remember them bragging about how many million seconds Windows 10 users used Edge and how many pictures they viewed in the Photo app. I regret not having saved that article back then as it seems they realized how bad that looks and deleted it.

nativeit · 1d ago
Try installing Adobe's Creative Cloud and/or any of its related products. I ultimately setup an instance of AdGuard just to block Adobe's insane telemetry traffic.
486sx33 · 1d ago
Pi hole adobe checks lol
hulitu · 1d ago
> but one network request every five minutes doesn't sound that bad to me

Even if it is made to CIA/GRU/chinese state security ? /s

gus_massa · 1d ago
From the article:

> Add special signals you can change on your server, which the app will understand, such as a forced update that will install without asking the user.

I don't like that part neither.

vrosas · 2d ago
When I built an app that “phones home” regularly, I added the ability for the backend to respond to the client with an override backoff that the client would respect over the default.
gblargg · 1d ago
Seems like the proper fix would have been to remove the file from the server when they realized the increased traffic. Then clients would just fail to check the update each time and not tie up bandwidth.
silverwind · 23h ago
There is a standard HTTP header for this: Retry-After.
nyarlathotep_ · 1d ago
Wish people would actually do things like this more often.

Plenty of things (like playstation's telemetry endpoint, for one of many examples) just continually phones home if it can't connect.

The few hours a month of playstation uptime shows 20K dns lookups for the telemetry domain alone.

SnorkelTan · 1d ago
Why not just use http retry-after? then you can use middleware/proxy to control this behavior. Downside here is that system operation becomes more opauqe and fragmented across systems.
vrosas · 1d ago
Because the client in this case is not a browser.
aziaziazi · 1d ago
Could you expend on what is an "override backoff" ?
ses1984 · 1d ago
The client might have a feature to retry certain failures, and it’s using a particular rate, probably not retrying n times one right after the other in rapid succession. This is called backoff.

The server can return an override backoff so the server can tell the client how often or how quickly to retry.

It’s nice to have in case some bug causes increased load somewhere, you can flip a value on the server and relieve pressure from the system.

vrosas · 1d ago
Exactly. Without going too deep into the architecture, the clients are sending data to the backend in real time, but often that data is not actionable during certain periods, so the backend can tell the clients to bundle the data and try again after a certain amount of time, or just discard the data it's currently holding and try again later (i.e. in 5/10/n seconds)
aziaziazi · 1d ago
Thanks for your responses. I’m used to "throttle", seems to be a synonym right?
vrosas · 1d ago
sure, you could say throttle.

No comments yet

treyd · 1d ago
Presumably the back end could tell the client not to check again for some amount of time. Sounds similar but different to cache TTLs, as those are passive.
Tade0 · 1d ago
Several months ago I was dealing with huge audio interruption issues - typical sign of some other, blocking, high-priority process taking too long.

Turns out Adobe's update service on Windows reads(and I guess also writes) about 130MB of data from disk every few seconds. My disk was 90%+ full, so the usual slowdown related to this was occurring, slowing disk I/O to around 80MB/s.

Disabled the service and the issues disappeared. I bought a new laptop since, but the whole thing struck me as such an unnecessary thing to do.

I mean, why was that service reading/writing so much?

crazygringo · 1d ago
Every 5 minutes is too often yes, but it hardly matters for a tiny HTTP request that barely has a body.

So yes it should only be once a day (and staggered), but on the other hand it's a pretty low-priority issue in the grand scheme of things.

Much more importantly, it should ask before downloading rather than auto-download. Automatic downloads are the bane of video calls...

therealpygon · 1d ago
I don’t know this software, but my sense is that this would be exactly the type of desired functionally in order to bypass rejected user metric sharing by parsing update request metrics, but maybe you are right and the Developers really do believe you can’t go more than 5 minutes on an out-of-date version…
londons_explore · 1d ago
Well designed software does not poll for anything - everything is event based.

In this case, that means an update should have been sent by some kind of web socket or other notification technology.

Today no OS or software that I'm aware of does that.

treve · 1d ago
So your conclusion is all software that polls is badly designed?

Keeping a TCP socket open is not free and not really desirable.

londons_explore · 1d ago
Most platforms offer other notification channels - ie. Web push. Those truly are free.
Chaosvex · 1d ago
No, those are abstraction over a TCP socket and introduce more complexity than you'd need for something like this. There's nothing wrong with occasionally polling for updates.
londons_explore · 1d ago
Web push, FCM, APNS, etc are free because they only have a single systemwide TCP channel open - and that channel is already open whether or not your app chooses to use it.

Your app can also be ready to receive notifications even when the app isn't running - using zero RAM. Inetd on Linux allows similar stuff (although no ability to handle ip changes or traverse NAT makes it fairly useless in the consumer world).

This stuff is important because polling dominates power use when idle - especially network polling which generally requires hundreds of milliseconds of system awakeness to handle tens of network packet arrivals simply for a basic http request.

Did you know, a typical android phone, if all polling is disabled, has a battery life of 45 days?

reassess_blind · 1d ago
An android phone on airplane mode has a battery life of 45 days?
londons_explore · 1d ago
Airplane mode and the scheduler disabled, yes (ie. So Apps don't wake up every 5 mins and attempt to contact the network).

It's actually required by the qualification process for lots of carriers. The built in apps have pretty much no polling for this reason.

During the qualification test, it's actually connected to both LTE and WiFi, but not actually transferring any data.

They cheat a little - the phone is not signed into a Google account, which makes pretty much all Google apps go idle.

thinkingemote · 1d ago
How does a user disable the scheduler?
londons_explore · 1d ago
That's quite oem specific, but usually 'battery saver' does it.
Chaosvex · 1d ago
That's a lot of abstraction to implement a simple update check and I suspect it's very much not worth it to save a minuscule amount of battery life on a laptop. This is ignoring that you're incorrect about how Web Push works, so you'd need that extra TCP connection anyway and at that point, there's no point in bothering with Web Push. FCM is the same deal (and now you get to pay for extra stuff for a trivial problem, woo) and APN seems like the wrong solution to auto-updates.

Just poll every launch or 24 hours and move on.

sandworm101 · 1d ago
Thats only half as bad as a certain company that had all thier users download an unwanted OS upgrade on the theory that one day they might click the install button by accident.

"We will stop filling your drives with unwanted windows 14 update files to you once you agree the windows 12 and 13 eulas and promise to never ever disconnect from the internet again."

esalman · 1d ago
* 12 times per hour per user.
jve · 2d ago
> Screen Studio is a screen recorder for macOS. It is desktop app. It means we need some auto-updater to allow users to install the latest app version easily.

No, it doesn't mean that.

Auto updater introduced series of bad outcomes.

- Downloading update without consent, causing traffic for client.

- Not only that, the download keeps repeating itself every 5 minutes? You did at least detect whether user is on metered connection, right... ?

- A bug where update popup interrupts flow

- A popup is a bad thing on itself you do to your users. I think it is OK when closing the app and let the rest be done in background.

- Some people actually pay attention to outgoing connections apps make and even a simple update check every 5 minutes is excessive. Why even do it while app is running? Do on startup and ask on close. Again some complexity: Assume you're not on network, do it in background and don't bother retrying much.

- Additional complexity for app that caused all of the above. And it came with a price tag to developer.

Wouldn't app store be perfect way to handle updates in this case to offload the complexity there?

HelloNurse · 2d ago
App store updates are perfect: no unnecessary complications, no unnecessary work (assuming Screen Studio is published and properly updated in the app store), and the worst case scenario is notifications about a new Screen Studio version ending up in a Screen Studio recording in progress.

Thinking of it, the discussed do-it-yourself update checking is so stupid that malice and/or other serious bugs should be assumed.

ryandrake · 2d ago
Exactly. The AppStore already exists and does updates (either automatically or manually, configurable by the user). The developer didn't have to lift a finger to get this functionality. Imagine sitting down and spending time adding functionality to your application that is already provided for free by the operating system, and then after all that, doing it incorrectly!
HelloNurse · 2d ago
Starting from the paid developer accounts, the Apple app store isn't "provided for free by the operating system" and it is a source of endless busywork, fear and suffering, but the argument stands: a professional Macintosh software vendor uses the app store because Macintosh users expect it, so it can be assumed that "properly" publishing new software version to the app store is a sunken cost that should be made as useful as possible.
ryandrake · 2d ago
By "provided for free" I mean the App Store comes with the OS, costs nothing (monetarily) to the developer over the existing annual Apple Developer Program fee, which pretty much all macOS developers pay anyway, and can be counted on to exist on all macOS installations.
Telemakhos · 2d ago
> malice and/or other serious bugs should be assumed

Going back to the blog post and re-reading it with this possibility in mind is quite a trip.

> It turns out thousands of our users had the app running in the background, even though they were not using it or checking it for weeks (!). It meant thousands of users had auto-updater constantly running and downloading the new version file (250MB) over and over again every 5 minutes

This could easily have been data exfiltration from client computers instead, and few (besides the guy whose internet contract got cancelled for heavy traffic) would have noticed.

n_ary · 1d ago
I find the misbehavior of indie/boutique MacOS apps always insisting on starting at login very irritating. Unless the app needs to run some heavy background preparation steps before becoming usable, there is literally no sense it starting at login. Also when dormant, check for update(once every 24h), and nag the user if they want to update, but please do not auto download! A lot of non-tech folks use 128/256GB versions of macbook with trillions of photos already clogging their device, an app downloading new updates to add to the pain unless the user asks to do so is outright malice.
bearjaws · 2d ago
Yeah no, publishing to the App Store is a nightmare in cost and time. I can 100% guarantee they still saved money on 30% fees even after this $8000 snafu.

Screen Studio has 32k followers, lets say 6% are end users, 2000 users at $229, that is $137k in App Store fees.

I am going to say writing your own app update script is a wash time wise, as getting your app published is not trivial, especially for an app that requires as many permissions as screen studio.

skinner927 · 2d ago
Some people don’t like using the AppStore. I like to keep backups of installers so I can control the version. And if it gets pulled from the AppStore, I’ll always have a copy.
Nition · 2d ago
While we're listing complaints... 250MB for a screen recorder update?
yojo · 2d ago
That’s pretty much the floor for an Electron app.

If you’re a small shop or solo dev, it is real hard to justify going native on three platforms when electron gives it for (near) free. And outside of HN, no one seems to blink at a 250MB bundle.

There are alternatives like Tauri that use the system browser and allow substantially smaller bundles, but they’re not nearly as mature as Electron, and you will get cross platform UI bugs (some of which vary by user’s OS version!) from the lack of standardization.

rafram · 2d ago
This app is Mac-only, which makes the choice to use Electron a little confusing.
yojo · 2d ago
That is… surprising.

I’d actually seen this project before because the author did a nice write up on using React portal to portal into electron windows[1], which is something I decided to do in my app.

I’d just assumed his was a cross platform project.

1: https://pietrasiak.com/creating-multi-window-electron-apps-u...

pcthrowaway · 1d ago
> And outside of HN, no one seems to blink at a 250MB bundle.

Please, many people connect to the internet via a mobile phone hotspot, at least occasionally.

This bug would likely cause you to go through your entire monthly data in a few hours or less.

yojo · 1d ago
I’m not excusing this bug. There are several poor decisions that went into this issue, but my contention is that using electron (with the resulting 250mb bundle) is not one of them.

You should probably not roll your own auto-updater.

If you do, checking every 5 minutes for updates is waaaay too often (and likely hurts battery life by triggering the radio).

And triggering a download without a user-prompt also feels hostile to me.

The app size compounds the problem here, but the core issue is bad choices around auto-updating

goodpoint · 1d ago
> And outside of HN, no one seems to blink at a 250MB bundle.

Except like 1 or maybe 2 billion people with slow or expensive internet.

zahlman · 1d ago
> And outside of HN, no one seems to blink at a 250MB bundle.

I can remember when I would have to leave a 250MB download running overnight.

Before that, I can remember when it would have filled my primary hard drive more than six times over.

... Why can't the app-specific code just get plugged into a common, reusable Electron client?

yojo · 1d ago
Different versions of electron bundle different versions of chromium. There can/will be rendering differences between them.

Tauri is an alternative framework that uses whatever web view the OS provides, saving ~200mb bundle size. On Mac that’s a (likely outdated) version of Safari. On Windows it’ll be Edge. Not sure what Linux uses, I’d guess it varies by distro.

The promise of Electron (and it’s an amazing value prop) is that your HTML/JS UI will always look and work the same as in your dev environment, no matter what OS the host is running.

I don’t have the time or inclination to test my app on the most recent 3 releases of the most popular operating systems every time I change something in the view layer. With Electron, I trade bundle size for not having to do so.

I do think alternatives like Tauri are compelling for simple apps with limited UI, or where a few UI glitches are acceptable (e.g. an internal app). Or for teams that can support the QA burden.

jasonjmcghee · 1d ago
You mean like WebKit which Tauri uses?
yojo · 1d ago
I go into more detail in a sibling comment, but Tauri does not provide a standardized web runtime. The webview you get depends on your OS and OS version. They’re all “WebKit”, but definitely do not all render the same. I have built a Tauri app and switched to Electron after encountering multiple x-plat rendering bugs.
crest · 2d ago
And even when nothing changed?!? Fucking lazy developers aka "I have an idle ≥1Gb/s pipe to the download server". What happened to rsync/zsync/zstd (with dictionary)? There are so many good tools freely available to reduce wasted bandwidth when you insist on reinventing the wheel. sigh
aidenn0 · 1d ago
I'd like to point out https://www.daemonology.net/bsdiff/ as a good, free, option for delta updates.
ivanjermakov · 2d ago
Screen recorder under 100 bytes: ffmpeg -video_size 1024x768 -framerate 25 -f x11grab -i :0.0+100,200 output.mp4
aidenn0 · 1d ago
Per [1] That would be 39MB (uncompressed; probably about half that compressed) to include ffmpeg-darwin-arm64, since OS X doesn't ship with ffmpeg installed.

1: https://news.ycombinator.com/item?id=43839120

sweetjuly · 1d ago
Screen recorder in under 100 bytes:

Open QuickTime and hit Command-Shift-N. Press record.

ljm · 1d ago
Screen recorder in 0 bytes: open camera app on phone and hit record.
watermelon0 · 1d ago
Last time I checked, statically built ffmpeg was 100 MB, at least on Linux.
aidenn0 · 1d ago
18.4MB compressed[1].

FWIW the transitive dependencies of the nixOS ffmpeg add up to 764MB, but dynamically linking is always much larger than statically linking, and that calculation will include more than just the shared-libraries.

Also note that he app includes an ffmpeg that is 39MB uncompressed.

1: https://johnvansickle.com/ffmpeg/ (based on the arm64 build, since TFA is an arm64 app).

areyourllySorry · 2d ago
you're not their target audience
cratermoon · 1d ago
does that work on MacOS?
ivanjermakov · 1d ago
Yes, but command is different: https://trac.ffmpeg.org/wiki/Capture/Desktop
c-hendricks · 1d ago
No, but cmd+shift+5 does.
cratermoon · 1d ago
TIL
amelius · 2d ago
As a user I hate auto updates. It feels like someone pulling the rug from under me.
socalgal2 · 2d ago
Does the app store handle staged rollouts?

That was a thing I thought was missing from this writeup. Ideally you only roll up the update to a small percent of users. You then check to see if anything broke (no idea how long to wait, 1 day?). Then you increase the percent a little more (say, 1% to 5%) and wait a day again and check. Finally you update everyone (who has updates on)

dahcryn · 2d ago
yes obviously something as mature as the App store supports phased rollout. I believe it is even the default setting once you reach certain audience sizes. Updates are always spread over 7 days slowly increasing the numbers
djxfade · 2d ago
Yes it does support this
dist-epoch · 2d ago
> Wouldn't app store be perfect way to handle updates

But then the HN crowd would complain "why use an app store? that's gate keeping, apple could remove your app any day, just give me a download link, and so on..."

You literally can't win.

wqaatwt · 2d ago
You can? Don’t check for updates every 5 minutes. Daily or even weekly would be sufficient for an app like this (if auto-updater is even necessary at all.. just show a notification)
abstractspoon · 2d ago
I find it ludicrous that the developers of an app as insignificant as a screen recorder would think it's necessary to check for updates every 5 minutes.

Once a day would surely be sufficient.

smallpipe · 2d ago
I make CPUs for a living. I'm happy these people exists, we'll always need faster CPUs.
VWWHFSfQ · 2d ago
The big clouds love these people too. So much of the software industry is just an outrageous combination of inexperience and "YOLO". Every problem can be solved by just giving AWS another $100,000 this month because we don't have time (and don't know how) to make even basically optimized software. So just burn the gas and electricity and give more money to the YAML merchants at Amazon.
999900000999 · 2d ago
That was the promise of "The Cloud".

Data centers are big and scary, no body wanted to run their own. The hypothetical cost savings of firing half the IT department was too good to pass up.

AWS even offered some credits to get started, first hit's free.

Next thing you know your AWS spend is out if control. It just keeps growing and growing and growing. Instead of writing better software, which might slow down development, just spend more money.

Ultimately in most cases it's cheaper in the short term to give AWS more money.

Apart of me wants to do a 5$ VPS challenge. How many users can you serve with 5$ per month. Maybe you actually need to understand what your server is doing ?

I'm talking non sense, I know.

maccard · 1d ago
I work for a big org. We’re about to deploy a small grafana setup for monitoring some test environments. Double digit spend per month, maximum. It’s pretty close to impossible to get IT, infosec, purchasing and finance to agree to this in a period of time that I’ll still be employed (and I’m not planning on leaving).

But, on the AWS marketplace I can click a button, a line item is added to our bill, and infosec are happy because it’s got the AWS checkmark beside it. Doesn’t matter what it costs, as long it goes through the catalog.

That’s why big companies use AWS.

At my last job, I worked for a vc backed startup. I reached out to our fund, and they put us in touch with AWS, who gave us $100k in credits after a courtesy phone call.

That’s why startups use AWS

sombrero_john · 1d ago
> Instead of writing better software, which might slow down development, just spend more money.

Except this is unironically a great value proposition.

ryandrake · 1d ago
We are throwing everything under the bus, including the user's battery, CPU, memory, bandwidth, the company's cloud costs and energy usage, just so developers can crap out software slightly faster.
sombrero_john · 11h ago
We are providing users with valuable features at a faster rate, saving them and us time, which is a far more valuable asset than "the user's battery, CPU, memory, bandwidth, the company's cloud costs and energy usage".
jayofdoom · 1d ago
Doing 'the cloud' right at scale has to involve running your own cloud at some point. We should not pollute the good ideas around API-delivered infrastructure with the more questionable idea of outsourcing your infrastructuree.

OpenStack has been around 15 years powering this idea at scale for huge organizatons, including Wal-Mart, Verizon, Blizzard and more.

skull723 · 1d ago
Not really. I run several web applications on one 15$ VPS. Although the user count is <5. But I think it would need quite a lot of users for the resource usage to go up to a critical level.
nyarlathotep_ · 1d ago
> outrageous combination of inexperience

Correction--many have years of inexperience. Plenty of people that do things like this have "7 years designing cloud-native APIs".

whstl · 1d ago
Oh, cloud native. For a few years people used to look at you funny if you were ...gasp... using battle-tested open source software instead of the overpriced AWS alternative. I'm so glad we're finally seeing pushback.
ngruhn · 2d ago
> the YAML merchants at Amazon

I lost it

rvz · 1d ago
> Every problem can be solved by just giving AWS another $100,000 this month because we don't have time (and don't know how) to make even basically optimized software.

Don't forget the Java + Kafka consultants telling you to deploy your complicated "micro-service" to AWS and you ending up spending tens of millions on their "enterprise optimized compliant best practice™" solution which you end up needing to raise money every 6 months instead of saving costs as you scale up.

Instead, you spin up more VMs and pods to "solve" the scaling issue, which you lose even more money.

It is a perpetual scam.

EvanAnderson · 2d ago
> Once a day would surely be sufficient.

Weekly or monthly would be sufficient. I'd also like "able to be disabled manually, permanently" as an option, too.

ryandrake · 2d ago
How about never? If I want to update my software, I'll update it. I don't need the application itself to hound me about it, at any frequency.
pixl97 · 2d ago
Because historically your average user will not update the software and then some worm is going about causing massive damage all over the internet.
EvanAnderson · 1d ago
This is overblown fear mongering, especially for desktop apps.

There are only a few applications with exposed attack surface (i.e. accept incoming requests from the network) and a large enough install base to cause "massive damage all of the Internet". A desktop screen recorder app has no business being constructed in a manner that's "wormable", nor an install base that would result in significant replication.

The software that we need the "average user" to update is stuff like operating systems. OS "manufacturers" have that mostly covered for desktop OS's now.

Microsoft, even though their Customers were hit with the "SQL Slammer" worm, doesn't force automatic updates for the SQL Server. Likewise, they restrict forcing updates only to mainstream desktop OS SKUs. Their server, embedded, and "Enterprise" OS SKUs can be configured to never update.

mgkimsal · 2d ago
Hrm... might depend on the purpose of the update. "New feature X" announcements every few days... I hate and disable. "Warning - update now - security bug"... I want to be notified of those pretty quickly.
hennell · 1d ago
Ironically the only real call for an update check every 5 mins would be so you can quickly fix a problem like everyone downloading the update every 5 mins.
pcthrowaway · 1d ago
> Once a day would surely be sufficient.

Well they might need to rush out a fix to a bug that could be harmful for the user if they don't get it faster.

For example, a bug that causes them to download 250MB every 5 minutes.

dist-epoch · 2d ago
You can use that as a hidden way of tracking how many active users you have at any time.

Good way of showing adoption and growth.

mystified5016 · 2d ago
You can still do that with daily, weekly, or monthly checks.

Nobody under any circumstances needs usage stats with 5 minute resolution. And certainly not a screen recorder.

panki27 · 2d ago
That's stretching my definition of "good" quite a bit.
closewith · 2d ago
You definitely can, although it would be unlawful under the GDPR without user consent, so you could never release the figures publicly.
ahtihn · 1d ago
It wouldn't if you're not tracking user identity.

Websites get this data pretty much by default and they don't need consent for it.

closewith · 1d ago
If you're deduplicating via IP or any other identifier, then it will be subject to the requirement for a legal basis.
alpaca128 · 18h ago
How so? You could just store a hashsum instead of an identifier.
chris_va · 2d ago
I generally find that these things are put in during development, and then people forget to take them out.
VladVladikoff · 2d ago
I honestly lost so much respect for the author after reading this that I completely bailed on the article. Every 5 minutes update check is entirely unhinged behaviour.
ljm · 1d ago
Why pay for your own runners when you can do CI/CD on your users’ machines?
ryukoposting · 1d ago
It's a fucking screen recorder. Why does it need to check for updates more than once a month? Why does it need to check for updates at all? It's an appliance. It either records your screen, or it doesn't.
Yeri · 2d ago
a thousand times this.
amelius · 2d ago
one time should be sufficient
spaqin · 2d ago
I would also put into question if you _really_ need to check for updates every 5 minutes. Once per startup is already enough, and if you're concerned about users who leave it on for days, it could easily be daily or even less often.
Lammy · 2d ago
A 5 minute update check interval is usage-reporting in disguise. Way fewer people would turn off a setting labeled “check for updates” than one labeled “report usage statistics”.
bilekas · 2d ago
Don’t give them ideas!!
Spivak · 2d ago
Eh, this one is probably ignorance over malice. It's super common to see people who need to make an arbitrary interval choice go with 300 out of habit.
YetAnotherNick · 2d ago
Do they say that they don't do any usage reporting?
TowerTall · 2d ago
from their FAQ on the buttom of the fronpage:

Screen Studio can collect basic usage data to help us improve the app, but you can opt out of it during the first launch. You can also opt out at any time in the app settings.

knowitnone · 2d ago
or they can send report usage statistics without you knowing or being able to disable it.
blitzar · 2d ago
never attribute to malice what can be attributed to incompetence
Lammy · 2d ago
No. Eradicate this line of thinking from your brain. If the outcome is the same then the intent doesn't matter.
llmthrow103 · 1d ago
In fact, assume the opposite unless you have a reason to assume otherwise (aka a close personal relationship). Giving strangers/businesses that you have no connection to the benefit of the doubt when they harm you is a good way to get taken advantage of.
GuinansEyebrows · 2d ago
Yes and one provides cover for the other.
o11c · 1d ago
Never contort your reasoning to attribute to incompetence what is much better explained by malice. Especially when politics or money is involved, malice should be the assumed default.
stevage · 2d ago
It's absolutely way too frequent.

Their users do not care about their screen recording studio anywhere near as much as the devs who wrote it do.

Once a month is probably plenty.

Personally, I disable auto-update on everything wherever possible, because the likelihood of annoying changes is much greater than welcome changes for almost all software I use, in my experience.

karhuton · 2d ago
To be as user friendly as possible, always ask if user wants automatic background updates or not. If you can’t update without user noticing it, please implement manual updates as two mechanisms:

1) Emergency update for remote exploit fixes only

2) Regular updates

The emergency update can show a popup, but only once. It should explain the security risk. But allow user to decline, as you should never interrupt work in progress. After decline leave an always visible small warning banner in the app until approved.

The regular update should never popup, only show a very mild update reminder that is NOT always visible, instead behind a menu that is frequently used. Do not show notification badges, they frustrate people with inbox type 0 condition.

This is the most user friendly way of suggesting manual updates.

You have to understand, if user has 30 pieces of software, they have to update every day of the month. That is not a good overall user experience.

zveyaeyv3sfye · 2d ago
> You have to understand, if user has 30 pieces of software, they have to update every day of the month. That is not a good overall user experience.

That's not an user issue tho, it's a "packaging and distribution of updates" issue which coincidentally has been solved for other OS:es using a package manager.

adrianN · 2d ago
Getting used to changes is not something a package manager can help with.
wqaatwt · 2d ago
Or a developer problem when they keep updating their apps every few days for no apparent reason..
tom1337 · 2d ago
I'd also question if the updater needs to download the update before the user saying they want it. Why not check against a simple endpoint if a newer version is available and if so, prompt the user that an update could be downloaded and then download it. This would also allow the user to delay the update if they are on metered connections.
firesteelrain · 2d ago
notepad++ works this way
canucker2016 · 2d ago
In the previous year 2023 discussion, the founder says that the update interval was changed to 3 hours. lol. see https://news.ycombinator.com/item?id=35873727

If the update interval had been 1 day+, they probably wouldn't have noticed after one month when they had a 5 minute update check interval.

m3adow · 2d ago
First thing I thought as well. Every 5 minutes for a screen recording software is an absurd frequency. I doubt they release multiple new versions per day.
ghurtado · 2d ago
IIRC, Every 5 minutes used to be the standard interval between email checks, back in the days of dialup and desktop email clients.

How the times have changed ..

lucb1e · 2d ago
It's near-instant now not usually because of more incessant polling, but because it simply keeps the connection open (can last many hours without sending a single byte, depending also on the platform) and writes data onto it as needed (IMAP IDLE). This has gotten more efficient if anything
pjmlp · 2d ago
And because how expensive they were in Portugal, I never done it, it was always on manual.
ghurtado · 1d ago
Right!

The "send and receive" button is seared into my brain

I was in Spain at the time, and at first you had to connect to the Internet through a phone number in France.

Did you guys have something like that?

pjmlp · 1d ago
In the early days, it was a long distance call to either Lisbon or Porto, I only got a modem, when regional numbers were available to the district capitals.

However on BBS days was much worse, it was mostly long distace calls to someone around the country, and they usually only had a couple of connections available like five or so.

Ah another thing is that they adopted the same model as mobile phones, so at least we could pre-pay the calls, and went we run out of cash there was it, no surprise bills, even if frustated.

sixtyj · 2d ago
Check for updates every 5 minutes is a bug itself ;)

It is sort of fun (for $8,000) as it was “just” a screenshotter, but imagine this with bank app or any other heavily installed app.

All cloud providers should have alerts for excessive use of network by default. And they should ask developers if they really want to turn alerts off.

I remember Mapbox app that cost much more, just because provider did charge by months… and it was a great dispute who’s fault it was…

trollbridge · 2d ago
And if it is necessary, the proper way to do this is via DNS with a record with a TTL less than 5 minutes, not pinging some webserver.

This could have easily been avoided by prompting the user for an update, not silently downloading it in the background... over and over.

wodenokoto · 2d ago
Depends on the application. I have my browser running for months at a time.
atoav · 2d ago
Yeah but that should be a variable anyways. Maybe even a variable provided by the server. But in this case it should be on demand. with the old version cached and only downloading the new one when there is a new version once a day.
atoav · 2d ago
Yeah but that should be a variable anyways. Maybe even a variable provided by the server.
donatj · 2d ago
I am always kind of a stickler about code reviews. I once had a manager tell me that I should leave more to QA with an offhand comment along the lines of "what is the worst that could happen" to which I replied without missing a beat "We all lose our jobs. We are always one bad line of code away from losing our jobs"

The number of times I have caught junior or even experienced devs writing potential PII leaks is absolutely wild. It's just crazy easy in most systems to open yourself up to potential legal issues.

ValdikSS · 2d ago
Yep, what's in most other jobs is a criminal offense, the most serious issue the individual developer could face is just to lose the job.
monkeyelite · 2d ago
If you demand accountability you need to grant authority.
monkeyelite · 2d ago
Code reviews kill velocity - introduce context switching, and are make work, it feels like you’re doing something to make a PR etc but your not.

The context it makes the most sense is accepting code from strangers in a low trust environment.

The alternative to trying to prevent mistakes is making it easy to find and correct them. Run CI on code after it’s been merged and send out emails if it’s failed. At the end of a day produce a summary of changes and review them asynchronously. Use QA, test environments, etc.

latexr · 1d ago
> Code reviews kill velocity

This feels like a strange sense of priorities which would be satirised in a New Yorker/Far Side single-panel comic: “Sure, my mistake brought down the business and killed a dozen people, but I’m not sure you appreciate how fast I did it”.

Code should be correct and efficient. Monkeys banging their heads against a keyboard may produce code fast, but it will be brittle and you’ll have to pay the cost for it later. Of course, too many people view “later” as “when I’m no longer here and it’s no longer my problem”, which is why most of the world’s software feels like it’s held together with spit.

monkeyelite · 1d ago
> would be satirised in a New Yorker/Far Side single-panel comic:

Thanks for taking my experience and comment seriously and challenging your preconceptions.

> Code should be correct and efficient.

When it ships to customers. The goal is to find the bugs before then. Having a stable branch can be accomplished in many ways besides gating each merge with a review.

Do you have any studies to show how effective synchronous code review is in preventing mistakes? If they are such a good idea why not do 2 or 3?

latexr · 1d ago
> Thanks for taking my experience and comment seriously and challenging your preconceptions.

I apologise if my comment read as mean. I wanted to make the joke and it may have overshadowed the point.

> Do you have any studies to show how effective synchronous code review is in preventing mistakes?

I could’ve been clearer. I’m not advocating for code reviews, I’m advocating for not placing “velocity” so high on the list of priorities.

> If they are such a good idea why not do 2 or 3?

This argument doesn‘t really make sense, though. You’ve probably heard the expression “measure twice, cut once”—you don’t keep measuring over and over, you do it just enough to ensure it’s right.

monkeyelite · 1d ago
> I’m not advocating for code reviews.

Well my comment is against synchronous code reviews. So we are not in disagreement.

> you do it just enough to ensure it’s right.

I agree. Each layer of review etc is a cost and has benefits. You want to pick an appropriate level.

donatj · 1d ago
> Thanks for taking my experience and comment seriously and challenging your preconception

I'm honestly curious what you're experience level is? I've never known a developer with more than a couple years of experience valuing velocity over financial stability

ljm · 1d ago
The up-front cost of code review can be easily be tripled or quadrupled when it’s distributed over several weeks after the fact in the form of unplanned work, each instance of which incurs its own cost of context switching, as well as the cost of potential rework.

The purpose of such a review is a deliberate bottleneck in the earlier stage of development to stop it becoming a much larger bottleneck further down the line. Blocking one PR is a lot cheaper than blocking an entire release, and having a human in the loop there can ensure the change is in alignment in terms of architecture and engineering practices.

CI/CD isn’t the only way to do it but shifting left is generally beneficial even with the most archaic processes.

monkeyelite · 1d ago
> The up-front cost of code review can be easily be tripled or quadrupled when it’s distributed over several weeks

You’re taking a more extreme position than the one I’m stating. You can review every day or every hour if you want.

> a deliberate bottleneck in the earlier stage

Wouldn’t it be better if we could catch bugs AND avoid the bottleneck? That’s the vision. Good intentions may disagree about how to accomplish that.

ljm · 1d ago
To catch bugs and avoid the bottleneck that is code review, you’re just moving the bottleneck to some point after merging the code, not before.

Like it or not you still have to stop what you’re doing to identify a bug and then fix it, which takes time away from planned feature work. You’re not optimising anything, you’re just adding fragility to the process.

As I said before, an issue localised to a PR in review blocks one person. An issue that has spread to staging or prod blocks the entire team.

mugsie · 1d ago
> Code reviews kill velocity

Yes, they kill your velocity. However, the velocity of a team can be massively increased by shipping small things a lot more often.

Stable branches that sit around for weeks are the real velocity killer, and make things a lot more risky on deployment.

monkeyelite · 1d ago
I agree with all of that - no contradiction.
Capricorn2481 · 2d ago
> Code reviews kill velocity - introduce context switching, and are make work

This is the same point three times, and I don't agree with it. This is like saying tests kill velocity, there's nothing high velocity about introducing bugs to your code base.

Everything introduces context switching, there's nothing special about code reviews that makes it worse than answering emails, but I'm not going to ignore an important email because of "context switching."

Everyone makes mistakes, code reviews are a way to catch those. They can also spread out the knowledge of the code base to multiple people. This is really important at small companies.

CI is great, but I have yet to see a good CI tool that catches the things I do.

monkeyelite · 1d ago
> This is the same point three times

No it isn’t. Fake work, synchronization, and context switching are all separate problems.

> code reviews are a way to catch those

I said you can do reviews - but there is no reason to stop work to do them.

Why not require two or three reviews if they are so helpful at finding mistakes?

I agree everyone makes mistakes - that’s why I would design a process around fixing mistakes, not screening for perfection.

How many times have you gone back to address review comments and introduced a regression because you no longer have the context in your head?

mugsie · 1d ago
> Why not require two or three reviews if they are so helpful at finding mistakes?

Places do? a lot of opensource projects have the concept of dual reviews, and a lot of code bases have CODEOWNERS to ensure the people with the context review the code, so you could have 5-10 reviewers if you do a large PR

monkeyelite · 1d ago
Does it make the code better? The best projects are the ones with the most review l?
cbsks · 1d ago
> Why not require two or three reviews if they are so helpful at finding mistakes?

For secure software, e.g. ASIL-D, you will absolutely have a minimum 2 reviewers. And that’s just for the development branch. Merging to a release branch requires additional sign offs from the release manager, safety manager, and QA.

By design the process slows down “velocity”, but it definitely increases code quality and reduces bugs.

monkeyelite · 1d ago
Once again let me reframe the mindset. Trying to get a perfect change where you anticipate every possible thing that will go wrong beforehand is impossible - or at least extremely costly. The alternative is to spend your effort on making it easy to find and fix problems after.
skydhash · 1d ago
You are not anticipating every possible bugs. It's mostly a learning experience for you and the team if it's done correctly. Someone may proposes another approach, highlight certain aspects that needs to be done "right" (definition may vary), let you know possible pitfalls, etc... It's not always LGTM.
loeg · 1d ago
> Why not require two or three reviews if they are so helpful at finding mistakes?

Diminishing returns, of course. I have worked places where two reviews were required and it was not especially more burdensome than one, though.

I catch so many major errors in code review ~every day that it's bizarre to me that someone is advocating for zero code review.

Capricorn2481 · 1d ago
> No it isn’t. Fake work, synchronization, and context switching are all separate problems

Context switching is a problem because it...kills velocity. Fake work is a problem because it kills velocity. You're saying it's time that could be better spent elsewhere, but trying to make it sound wider. I disagree with the premise.

Synchronization is a new word, unrelated to what you originally wrote.

> How many times have you gone back to address review comments and introduced a regression because you no longer have the context in your head?

Never? I am not unable to code in a branch after a few days away from it. If I were, I would want reviews for sure! Maybe you have had reviews where people are suggesting large, unnecessary structural changes, which I agree would be a waste of time. We're just looking for bug fixes and acceptably readable code. I wouldn't want reviewers opining on a new architecture they read about that morning.

monkeyelite · 1d ago
> Synchronization is a new word, unrelated to what you originally wrote.

I believe you can figure it out.

> Never?

Ok well I’m trying to talk to people who have that problem. Because I and my team do.

skydhash · 1d ago
I guess they say never, because if you have descriptive commit messages and write good PR description, it's easy to regain the context surrounding the change. It's all about communication, both to others and your future self.
canucker2016 · 2d ago
...And if there's no one around to review the code?

The website makes it seem like it's a one person shop.

alias_neo · 2d ago
When I work on my own code, at home, with no-one to assist or review, I write tests, and open a PR anyway, and review it myself, sometimes the next day with fresh eyes, or even 10 minutes later after a quick walk in and out of the room and a glass of water.

If you're not confident you can review a piece of code you wrote and spot a potentially disastrous bug like the one in OP, write more tests.

zarzavat · 1d ago
Humans are very good at not spotting their own mistakes, that's why writers have editors.
rs186 · 1d ago
These days you can dump your code/diff to ChatGPT and ask it to criticize. Often most of it is junk -- irrelevant or incorrect suggestions. But the 1 in 10 suggestions is actually useful and correct, which can be immensely helpful.
albert_e · 2d ago
What about the bandwidth burned needlessly for thousands of users on their data plans.

At some scale such careless mistakes are going to create real effects for all users of internet through congestion as well.

If this was not a $8000 mistake but was somehow covered by a free tier or other plan from Google Cloud, would they still have considered it a serious bug and fixed it as promptly?

How many such poor designs are out there generating traffic and draining common resources.

bee_rider · 2d ago
They mention specifically handling the situation for one user. So, I guess it is a case-by-case thing.
gwbas1c · 2d ago
In comparison, when I shipped a Mac desktop application:

We used Sparkle, https://sparkle-project.org/, to do our updates. IMO, it was a poor choice to "roll their own" updater.

Our application was very complicated and shipped with Mono... And it was only about ~10MB. The Windows version of our application was ~2MB and included both 32-bit and 64-bit binaries. WTF are they doing shipping a 250MB screen recorder?

So, IMO, they didn't learn their lesson. The whole article makes them look foolish.

latexr · 1d ago
> WTF are they doing shipping a 250MB screen recorder?

250 MB is just the download DMG, the app itself is almost 550 MB. It’s an Electron app.

BeFlatXIII · 1d ago
550 megs?!?!?? On Apple’s unreasonably stingy SSD sizes?

Who would be foolish enough to download that?

ericmcer · 1d ago
People are willing to trade performance/size for convenience. Writing your application using Electron + React means it is going to probably ship a > 500mb app that will suck up 500mb ram while running, but you have a much easier dev experience and can deliver a "flashy" UI with minimal effort.
gwbas1c · 1d ago
Our 10MB was also for a "much easier dev experience" on Mac. The framework we shipped was basically 4x the size of the application.
rvz · 1d ago
> The Windows version of our application was ~2MB and included both 32-bit and 64-bit binaries. WTF are they doing shipping a 250MB screen recorder?

Electron.

> So, IMO, they didn't learn their lesson. The whole article makes them look foolish.

The lesson is to do better testing and write automated tests and don't roll your own updater.

jarym · 2d ago
Just amazed that ‘better testing’ isn’t one of the takeaways in the summary.

Just amazed. Yea ‘write code carefully’ as if suggesting that’ll fix it is a rookie mistake.

So so frustrating when developers treat user machines like their test bed!

hbsbsbsndk · 2d ago
I worked on a product where there was basically no automated testing, just a huge product surface to click around with a bunch of options. Because of technical debt some of the options would trigger different code paths, but it was up to the developer to memorize all the code paths and test accordingly.

After I shipped a bug the Director of Engineering told me I should "test better" (by clicking around the app). This was about 1 step away from "just don't write bugs" IMO.

stevage · 2d ago
Yep, my first job was at a company like that. Huge Windows desktop app built in Delphi. No automated testing of any kind. No testing scripts either. Just a lot of clicking around.
cryptonym · 2d ago
My first job was exactly that, selling windows app in Delphi. I joined the new team working on .net windows apps and we had an army of people clicking on UI all day long. They maintained their "test plan" on a custom software where they could report failures.

TBH, that was well done for what it was but really called for automation and lacked unit-testing.

HdS84 · 1d ago
I am forced to use a custom kv store for my current t project. That pos has a custom dsl, which can only be imported through a swing ui, by clicking five buttons. Also, the ui is for 1024 screens, they are tiny in my 4k monitor
01HNNWZ0MV43FF · 2d ago
I remember a test plan in a spreadsheet where no test had an ID.

I wish I could teach everything I learned the hard way at that job

hbsbsbsndk · 1d ago
To be clear this is a pretty modern company, not 10 years ago. CI/CD absolutely was a common best practice.
fifilura · 2d ago
Contrarian approach: $8000 is not a lot in this context. What did the CEO think of this? Most of the time it is just a very small speed bump in the overall finances of the company.

Avoidable, unfortunate, but the cost of slowing down development progress e.g. 10% is much higher.

But agree that senior gatekeepers should know by heart some places where review needs to be extra careful. Like security pitfalls, exponential fallback of error handling, and yeah, probably this.

stevage · 2d ago
I'm sure it cost a lot more than $8000. That was only the direct visible cost to them. There were likely users hit with costs for the additional downloads, who never even knew what was the issue. Users working on a mobile hotspot who had to pay for extra data etc etc.
latexr · 1d ago
> What did the CEO think of this?

I doubt there’s a CEO. Despite the use of “we”, pretty sure this is one guy building the app. All the copyright notices and social media go back to one person.

No comments yet

rvz · 2d ago
Imagine if that was Meta that had over 1B users with their messenger desktop app update functionality that did just that. The loss would be in the hundreds of millions.

> But agree that senior gatekeepers should know by heart some places where review needs to be extra careful. Like security pitfalls, exponential fallback of error handling, and yeah, probably this.

The lesson here is much better use of automated tests (The app likely has no tests at all) and proper use of basic testing principles like TDD would prevent such junior-level embarrassing bugs creeping up in production paid software.

That is the difference between a $100 problem vs a $200M problem.

See the case of Knight Capital [0] who lost $460M, due to a horrific deploy.

[0] https://www.henricodolfing.com/2019/06/project-failure-case-...

Klaster_1 · 2d ago
How do you adjust your testing approach to catch cases like this? In my experience, timing related issues are hard to catch and can linger for years unnoticed.
doix · 2d ago
I would mock/hook/monkey patch/whatever the functions to get the current time/elapsed time, simulate a period of time (a day/week/month/year/whatever), make sure the function to download the file is called the correct amount of times. That would probably catch this bug.

Although, after such a fuck up, I would be tempted to make a pre-release check that tests the compiled binary, not any unit test or whatever. Use LD_PRELOAD to hook the system timing functions(a quick google shows that libfaketime[0] exists, but I've never used it), launch the real program and speed up time to make sure it doesn't try to download more than once.

[0] https://github.com/wolfcw/libfaketime

01HNNWZ0MV43FF · 2d ago
Similar to doix said, consider reading the time as IO and then rewrite the code in sans-IO style so you can inject the time.

Then it's a unit test that looks too obvious to exist until you read the ticket mentioned in the comment above it

No need for monkey patching or hooking or preload

But before that you add a couple checkmarks to the manual pre-release test list: "1 hour soak test" and "check network transfer meters before and after, expect under 50 MB used in 1 hour (see bug #6969)"

In Linux they're under /sys/class/net I think

ikiris · 1d ago
I imagine they’d have to start testing first…
coip · 1d ago
not to ~dupe my top-level comment, but ETag headers can be used to manage this from a ~caching perspective
256_ · 1d ago
I don't think the author is wrong for saying that certain kinds of code should be written carefully. I object to the implication that other code shouldn't.

From TFA: "Write your auto-updater code very carefully. Actually, write any code that has the potential to generate costs carefully." So the focus is on code that "generate[s] costs". I think this is a common delusion programmers have; that some code is inherently unrelated to security (or cost), so they can get lazy with it. I see it like gun safety. You have to always treat a gun like it's loaded, not because it always is (although sometimes it may be loaded when you don't expect it), but because it teaches you to always be careful, so you don't absent-mindedly fall back into bad habits when you handle a loaded one.

Telling people to write code carefully sounds simplistic but I believe for some people it's genuinely the right advice.

stevage · 2d ago
>Just amazed that ‘better testing’ isn’t one of the takeaways in the summary.

I don't get the impression they did any testing at all.

jlarocco · 1d ago
They were using a typed language, so testing was unnnecessary ;-)
rvz · 1d ago
Quite shameful if it was a language based on Javascript with zero tests in 2025.
jmull · 2d ago
I'm pretty conservative about adopting third-party libraries (due to the long-term issues each one has the potential to cause), but an app updater is probably worth it.

It's just tricky, basically one fat edge case, and a critical part of your recovery plan in case of serious bugs in your app.

(This bug isn't the only problem with their home-grown updater. Checking every 5 min is just insane. Kinda tells me they aren't thinking much about it.)

wolrah · 2d ago
> I'm pretty conservative about adopting third-party libraries (due to the long-term issues each one has the potential to cause), but an app updater is probably worth it.

Especially for a Mac-only application where Sparkle (https://sparkle-project.org/) has been around for almost two decades now and has been widely used across all sorts of projects to the point that it's a de facto standard. I'd be willing to bet that almost every single Mac "power user" on the planet has at least one application using Sparkle installed and most have a few.

Zambyte · 2d ago
Or better yet, let the system package manager do it's job.
wqaatwt · 2d ago
You’d be forced to use Apple’s App-Store, though? I don’t think there is an other package manager
Zambyte · 2d ago
As far as system package managers go, yeah. That's part of the price you pay for choosing Apple (Knows Best) TM. There is brew, nix and the like for applications on MacOS too though.
madeofpalk · 2d ago
Apple doesn't "know best" - it's just that that is what the system package manager is.

You can use whatever you want outside of the App Store - most will use Sparkle to handle updates https://sparkle-project.org/. I presume Windows is similar.

Zambyte · 1d ago
> Apple doesn't "know best" - it's just that that is what the system package manager is.

The fact that that is what the system package manager is is why I said Apple "knows best". You can pick from dozens of system packages managers hooked up to hundreds, if not thousands of different repos on Linux.

ValdikSS · 2d ago
I'm running an anti-censorship proxy service which uses Proxy Auto-Configuration (PAC) file which you can configure OS-wide or in the browser.

If the file contains invalid JS (syntax error, or too new features for IE on Win7/8), or if it's >1MB (Chromium-based browsers & Electron limit), and the file is configured system-wide, then EVERY APP which uses wininet starts flooding the server with the requests over and over almost in an endless loop (missing/short error caching).

Over the years, this resulted in DDoSing my own server and blackholing its IP on BGP level (happened 10+ times), and after switching to public IPFS gateways to serve the files, Pinata IPFS gateway has blocked entire country, on IPFS.io gateway the files were in top #2 requests for weeks (impacting operational budget of the gateway).

All of the above happens with tight per-IP per-minute request limits and other measures to conserve the bandwidth. It's used by 500 000+ users daily. My web server is a $20/mo VPS with unmetered traffic, and thanks to this, I was never in the situation as the OP :)

sevg · 2d ago
Why in the world does it need to check for updates every 5 minutes?

The author seemed to enjoy calculating the massive bandwidth numbers, but didn’t stop to question whether 5 minutes was a totally ridiculous.

knowitnone · 2d ago
that's how frequent they find bugs in their app?
danpalmer · 2d ago
> We decided to take responsibility and offer to cover all the costs related to this situation.

Good on them. Most companies would cap their responsibility at a refund of their own service's fees, which is understandable as you can't really predict costs incurred by those using your service, but this is going above and beyond and it's great to see.

weird-eye-issue · 2d ago
"Luckily, it was not needed"
999900000999 · 2d ago
Sloppy coding all around. If you don't want to program something right, why don't you just direct users to the website to manually update it?

On one hand it's good that the author owns up to it, and they worked with their users to provide remedies. But so many things aren't adding up. Why does your screen recorder need to check for updates every 5 minutes? Once a day is more than enough.

This screams "We don't do QA, we shorts just ship"

Cthulhu_ · 2d ago
Or, given it's a Mac app, just have the Mac app store take care of updates. That's part of the value that using the app store service gives you, the other one being not spending thousands in accidental data transfer when you do auto updates wrong.
rvz · 1d ago
> Or, given it's a Mac app, just have the Mac app store take care of updates. That's part of the value that using the app store service gives you,

And pay Apple their 30% cut on your revenue? No thanks.

> the other one being not spending thousands in accidental data transfer when you do auto updates wrong.

Or just actually write proper automated tests for basic features first, before a large refactor to prevent introducing issues like this from happening again?

While I respect the author's honesty in this mistake, the main takeaway here is not mentioned and that is just writing proper automated tests as their impression on this post is that there aren't any.

jbverschoor · 1d ago
2% of that already goes to stripe or whatever you use. after a year it's 15%. It also gives your both a distribution and marketing channel.

It was good enough for netflix etc.

*I* don't want applications to be able to update itself. Look at malware zoom for example.

It's funny that people don't like telemetry, but at the same time they're ok with regular software update checks + installs.

Chaosvex · 1d ago
The same Netflix that's been spats with Apple over avoiding app store fees by flouting policies that had other apps kicked out of the store? I'd suggest that it was, in fact, not good enough for Netflix.
ryandrake · 2d ago
Software doesn't need to check for updates at all. If I want to update my software, I'll update it. I don't need or want the software to be doing it on its own. All OS's have a native package manager at this point that can handle updates. We don't need applications going around it.
999900000999 · 2d ago
A quick warning "Hi User, your out of date, please update." Is fair.

What's really scary here is the lack of consent. If I want to record videos I don't necessarily have an extra 250mb to spend( many users effectively pay by the gig) everytime the developer feels like updating.

coip · 1d ago
sad how many places take the position of "prod is QA and users are the best testers" lol
999900000999 · 1d ago
No meaningful consequences exist.

So why not ?

coip · 18h ago
from tfa

> One of our users, who lived in a house, had their internet provider cancel their contract due to enormous traffic generated during a month. It was extremely problematic as there was no other internet provider available around.

so, ¯\_(ツ)_/¯

mimimi31 · 2d ago
>Add special signals you can change on your server, which the app will understand, such as a forced update that will install without asking the user.

I understand the reasoning, but that makes it feel a bit too close to a C&C server for my liking. If the update server ever gets compromised, I imagine this could increase the damage done drastically.

mgkimsal · 2d ago
> The app checks for the update every 5 minutes or when the user activates the app. Normally, when the app detected the update - it downloaded it and stopped the 5 minutes interval until the user installed it and restarted it.

This is still bad. I was really hoping the bug would have been something like "I put a 5 minute check in for devs to be able to wait and check and test a periodic update check, and forgot to revert it". That's what I expected, really.

metaphor · 2d ago
indymike · 2d ago
We just put a header for version in our app, and when we deploy new code the client checks against the version header and upgrades if the version is mismatched. No extra get requests required. Bonus: we just use the last git commit hash as the version. Stupid simple.
01HNNWZ0MV43FF · 2d ago
I saw some project that used a DNS TXT field to check its version

That way I guess you get the caching of the DNS network for free, it uses basically one packet each way, encryption is still possible, and it can reduce the traffic greatly if a big org is running a thousand instances on the same network

I think it was written in Go. Might have been Syncthing

moi2388 · 2d ago
Why on earth are you checking for updates every 5 minutes to begin with?!

Seriously this alone makes me question everything about this app.

dkdbejwi383 · 2d ago
Probably product owner wants to show off a nice chart at their next meeting showing how quickyl users upgrade, as some kind of proxy metric for "engagement"
turbonaut · 2d ago
‘Simple’ bugs get a bit more expensive than this…

https://en.m.wikipedia.org/wiki/Knight_Capital_Group#2012_st...

440m usd

vishnudeva · 2d ago
The scale is astounding. I was briefly interested in the person that caused the error then immediately realized it was irrelevant because if a mechanism doesn't exist to catch an issue like that, then any company is living on borrowed time.
voidUpdate · 2d ago
whyyy does wikipedia not redirect mobile links to the desktop website when you have a desktop UA?
xigoi · 2d ago
Why do they have a separate mobile website at all instead of writing proper CSS to make one website work on all devices?
wodenokoto · 2d ago
Because people on desktops asking for the mobile site should be able to view the mobile site.

The url specifically asks Wikipedia to serve the mobile site.

voidUpdate · 2d ago
Well when I follow a desktop link on my phone, it redirects me to the mobile version, despite the URL specifically asking to serve the desktop site, it just doesn't work the other way around. Plus I never asked to see the mobile site, I followed a link someone else posted
BeFlatXIII · 1d ago
Why do people spam the mobile URL, leading me to degraded reading experiences?
creatonez · 2d ago
See also: Every time a small error in a spreadsheet has caused a huge problem https://eusprig.org/research-info/horror-stories/
saretup · 2d ago
Not to mention the cost users paid to download 250 MB every 5 minutes.
ghurtado · 2d ago
It seems a bit self centered to make their lost $8000 the focus of the article.

The title should have been: "how a single line of code cost our users probably more than $8000"

stevage · 2d ago
Totally. I live in a place where many (most?) ISP plans have limited monthly downloads. I'd be so pissed off if my monthly allowance was blown by this series of boneheaded decisions.
pests · 2d ago
It was mentioned, at the bottom. One customer even had their ISP cancel their service.
stevage · 2d ago
I'm really surprised this could happen. As they note:

> Write your auto-updater code very carefully.

You have to be soooo careful with this stuff. Especially because your auto-updater code can brick your auto-updater.

It looks like they didn't do any testing of their auto update code at all, otherwise they would have caught it immediately.

jlarocco · 1d ago
More anecdata that commercial software is garbage, especially if it's targetting consumers.

I'll stick with open source. It may not be perfect, but at least I can improve it when it's doing something silly like checking for updates every 5 minutes.

indrex · 2d ago
Plenty of (valid) criticism in the comments, but I appreciate the developer for publishing it.
pandemic_region · 2d ago
This 1000 times. It takes courage to open up to mistakes. As a relatively young industry, we have a lot to learn still to move away from the instinctive blaming culture surrounding such failures. In this case, it's only a file being downloaded a couple of times, nobody died or got injured.

For those interested in this topic, and how other industries (e.g. Airline industry) deal with learning from or preventing failure: Sidney Dekker is the authority in this domain. Things like Restorative Just Culture, or Field guide to understanding human error could one day apply to our industry as well: https://sidneydekker.com/books.

stevage · 2d ago
I feel a bit iffy about turning the shitty experience you imposed on your users into content for your blog.
oldgregg · 1d ago
What's in that payload when they check for updates every 5 minutes?!

Novel dark pattern: You unchecked "Let us collect user data" but left "Automatically Update" checked... gotcha bitch!

Olshansky · 1d ago
Reminds me of some Twitter lore from 2012. I was just an intern....

This is back in the Rails days, before they switch to Scala.

I heard that there was a fail-whale no one could solve related to Twitter's identity service. IIRC, it was called "Gizmoduck."

The engineer who built it had left.

They brought him in for half a day of work to solve the P0.

*Supposedly*, he got paid ~50K for that day of work.

Simultaneously outrageous but also reasonable if you've seen the inside of big tech. The ROI is worth it.

That is all.

Disclaimer: don't know if it's true, but the story is cool.

ikiris · 1d ago
If a half day fix from a former employee costs that much, it’s likely because the company deserved it for some reason.
jiggawatts · 2d ago
These articles are great, but I have to one-up the blog: I recently helped a small dev team clean up a one-line mistake that cost them $95,000... which they didn't notice for three months.

The relevance is that instead of checking for a change every 5 minutes, the delay wasn't working at all, so the check ran as fast as possible in a tight loop. This was between a server and a blob storage account, so there was no network bottleneck to slow things down either.

It turns out that if you read a few megabytes 1,000 times per second all day, every day, those fractions of a cent per request are going to add up!

hardwaresofton · 2d ago
Bugs are great chances to learn.

What might be fun is figuring out all the ways this bug could have been avoided.

Another way to avoid this problem would have been using a form of “content addressable storage”. For those who are new, this is just a fancy way of saying make sure to store/distribute the hash (ex. Sha256) of what you’re distributing and store it on disk in a way that content can be effectively deduplicated by name.

It’s probably not so easy as to make it a rule, but most of the time, an update download should probably do this

ghurtado · 2d ago
> out all the ways this bug could have been avoided.

The most obvious one is setting up billing alerts.

Past a certain level of complexity, you're often better off focusing on mitigation that trying to avoid every instance of a certain kind of error.

HelloNurse · 2d ago
Note that billing alerts protect against unexpected network traffic, not directly against bugs and bad design in the software. Update checking remains a terrible idea.
aranw · 2d ago
I have Screen Studio and I don't leave it open but all I wish for now is that you disable the auto updater. Provide an option for it to be disabled and allow for manual update checking. Checking for an update every 5 minutes is total overkill and downloading the update automatically is just bad. What if I was on mobile internet and had limited bandwidth and usage. The last thing I want is an app downloading it's own update without my consent and knowledge.
chinchilla2020 · 1d ago
"A single line of code caused <BUG>"

Yes, a single line of code is in the stack trace every time a bug happens. Why does every headline have to push this clickbait?

All errors occur at a single line in the program - and every single line is interconnected to the rest of the program, so it's an irrelevant statement.

pornel · 2d ago
It would also be nice if the update archive wasn't 250MB. Sparkle framework supports delta updates, which can cut down the traffic considerably.
mathverse · 2d ago
This is an electron app.
pornel · 1d ago
Which is even better for incremental updates.

If just some JavaScript files change, you don't need to redownload the entire Chromium blob.

dahcryn · 2d ago
which is their design choice, not an obligation.

Electron really messed up a few things in this world

zarzavat · 1d ago
Bug notwithstanding, checking for updates every 5 minutes is exactly the wrong way to do it.

You want to spread out update rollouts in case of a catastrophic problem. The absolute minimum should be once a day at a random time of day, preferably roll out updates over multiple days.

felineflock · 2d ago
From the article: "While refactoring it, I forgot to add the code to stop the 5-minute interval after the new version file was available and downloaded. It meant the app was downloading the same 250MB file, over and over again, every 5 minutes."
huksley · 2d ago
They had no cost usage alerts. So they even did not know that the thing was happening, just realized with the first bill.

I think that is the essence of what is wrong with the cloud costs. Defaulting to possibility for everyone to scale rapidly while in reality 99% have quite predictable costs month over month.

bryanrasmussen · 2d ago
I read that as "A single line of code costs $8000" which, from the comments seems like a few others had the same thought. Reading the article it is not costs and the original title is "One line of code that did cost $8,000", so as some others have pointed out it is a bug that cost $8000.
stevage · 2d ago
I was expecting it to be about a good line of code that cost $8,000 in development time to write, which might be an interesting story.
coffeeenjoyer · 2d ago
I assume most of that 2PB network traffic was not egress, right? Otherwise how did it "only" cost you $8k on Google Cloud? Even at a cost of 0.02$ per GB, which is usually a few times lower than the actual prices I could find there, that would still result in an invoice of about $40k...
CodesInChaos · 1d ago
The first 500TB should have cost $35k already. At that point pricing goes from $0.06/GB to "contact us". So I'd have expected google to charge $80k or so for the whole thing. (Unless google decided to forgive most of the cost)
leoapagano · 2d ago
Ignoring the obvious question of "why does a screen recorder that checks for updates every 5 minutes need to be installed if macOS already has a screen recorder built in"—writing your own (buggy) auto updater for a macOS app, in 2025, is nuts considering you also have two existing options for auto updates at your disposal, the Mac App Store and Sparkle (https://sparkle-project.org/), both of which are now nearly two decades old.
mudkipdev · 1d ago
>Add special signals you can change on your server, which the app will understand, such as a forced update that will install without asking the user.

Seems like a great idea, surely nothing can go wrong with that which will lead to another blog post in the near future

vachina · 2d ago
Does the developer release a tag for every ctrl+s.
Hobadee · 2d ago
Why is nobody talking about what a shady business practice it is that cloud providers don't alert you to this kind of overage by default? Sure, you can set up alerts, but when you go 10x over your baseline in a short period of time, that should trigger an alert regardless of your configured alerts.
bee_rider · 2d ago
They could compare against the baseline, I guess.

In the grand scheme of things, $8k is not much money for a business, right? Like we can be pretty sure nobody at Google said “a-ha, if we don’t notify the users, we will be able sneak $8k out of their wallets at a time.” I think it is more likely that they don’t really care that much about this market, other than generally creating an environment where their products are well known.

firesteelrain · 2d ago
Or treat it like the stock market and shut it down.
aserafini · 2d ago
I had one of these, an emoji was inserted into a notification SMS which doubled SMS costs due to encoding.
philomath_mn · 1d ago
While this unfortunate, I am sure I also have single lines in production with greater cost and equivalent value (close to none) -- and I've only worked at small companies. I am sure some of y'all can beat this by ~2 orders of magnitude.

Databricks is happy to have us as a customer.

kovac · 2d ago
CI/CD at it's finest :p I guess the 5-minutely updates is correlated with the rate of bug fixes they need to push... Surely, that can't be for new features.

Looking at the summary section, I'm not convinced these guys learned the right lesson yet.

rvz · 2d ago
CI/CD is part of the solution, but it is really just proper testing.

Nothing has been learned in this post and it has costed him $8,000 because of inadequate testing.

jumploops · 2d ago
Oh boy, I know of at least one case where a single line of code cost ~$500k…

Curious where the high-water mark is across all HNers (:

explodes · 2d ago
Others have reported higher already, but for data:

Our team had a bug that cost us about $120k over a week.

Another bug running on a large system had an unmeasurable cost. (Could $K, could be $M)

agos · 2d ago
I would be surprised if half of the user on this site did _not_ create or personally see a bug where a line cost way more than $8000
short_sells_poo · 2d ago
$1.2mln, gone in about 30 minutes.
Bluescreenbuddy · 2d ago
Meanwhile over at Knight Capital...
hollow-moe · 1d ago
Lesson learned: use OBS Studio
kaiwenwang · 1d ago
enceladus76 · 2d ago
For me this shows once again that proper testing is neglected by many developers and companies. Sadly, it is not even mentioned in the advice at the end of the article.
rvz · 1d ago
Exactly. No mention of writing automated tests or even TDD at all.

It's best to save everyone by writing tests that prevent a $100 issue on your machine from becoming a costly $10M+ problem in production as the product scales after it has launched.

This won't be the last time and this is what 'vibe coding' doesn't consider and it it will introduce more issues like this.

Always42 · 1d ago
$8000 is nothing for most companies, if you have 10 developers making 100k a year your burn rate is $4000 a day just for salaries.
dimatura · 1d ago
$8000 also seems pretty cheap for 2PB of traffic? Looking at google cloud storage egress rates, $0.02/GiB (which is on the lower end, since it depends on destination) would be about $40k for 2PB.
insin · 2d ago
Knowing where to put the line: $7999 (is sadly not the story)
timhigins · 1d ago
Screen studio does make the best-looking demo videos I've seen. Any favorite alternatives? Points for free or open source.
latexr · 1d ago
sota_pop · 1d ago
Didn’t read the article, but why would an app not just check for updates on startup/shutdown?
surfmike · 1d ago
Contact a rep at Google, they can probably reverse a good portion of the $8000 as a one-time thing.
poleguy · 2d ago
Ever consider not using cloud for everything? Hosting this on traditional hosting would have limited the problem and the cost.
M95D · 2d ago
And in that case, the problem would not be discovered until 1) someone opened a bug report, which rarely happens, because any competent user would just disable auto-updates, and 2) that bug report would be investigated, which also rarely happens.
cess11 · 2d ago
It's not like you are forbidden to monitor your services just because you didn't put them in big clown.
jensenbox · 2d ago
You need https://www.vantage.sh

Set up daily emails.

Set up cost anomaly alerts.

handfuloflight · 2d ago
Would have cost $0 on Cloudflare's R2.
misiek08 · 2d ago
So it is 2PB less of bytes written lifetimes on users disks? Interesting to count that.
Fokamul · 2d ago
Truth to be told, Google Cloud console is horrible mess for new people, who just wants quickly setup API, pay and don't have time to care about it anymore.

Well, you should hire contractor to set console for you.

"Designed for MacOS", aah don't worry, you will have the money from apes back in the no time. :)

nikanj · 2d ago
With public sector procurement, $8000 is a pretty standard price for a line of code.
ant6n · 2d ago
Do you mean "a" line of code, or "each" line of code?
nikanj · 2d ago
A dead-simple 1000-line app? $8 million from Accenture, IBM or similar
n_ary · 1d ago
Here is the example of why LLMs need to replace some douchbag SWE. But then again, unless there is a nutcase product owner involved, update check every 5min and downloading automatically is pure symptom of bad engineering practices and fear driven development(if anything breaks update is 5min away and we can laugh at the user when their app is updated and they are baffled).

Good thing, this was not shopify/Duolingo/Msft, else the news would be, how AI saved us $8k by fixing a dangerous code and why AI will improve software quality.

epolanski · 2d ago
I'm actually surprised by how cheaply they got away with.
navigate8310 · 2d ago
So did you pay or Google showed you mercy by chewing their potential earnings?
byyll · 2d ago
I'll let my employer know to update my salary or reduce my workload.
cyprx · 2d ago
meanwhile the CTOs plan to apply AI into their production codebases :)
kimbernator · 2d ago
This cost -you- $8000. It probably cost users a lot more.
a_t48 · 1d ago
I’ve done worse. At my very first job I wrote some slow login rewards calculation code for a mobile game that caused a black screen on startup for long enough that users thought the app was broken and closed it out. (I was simulating passing time one minute at a time in lua or some BS. Oops!) It cost the company some large fraction of my salary at the time. My boss very kindly said that it was okay, everyone ends up mucking up like that at some point in the career, and no I wasn’t fired because the company just spend a large sum teaching me a lesson. We sat down at a whiteboard and I quickly came up with a solution that could just calculate the rewards one should get between two dates - there was some complexity that made this harder than it sounds on paper, but simulating time manually was not the answer.
mmmlinux · 1d ago
Or you could use the built in screen recorder...
bilekas · 2d ago
> While refactoring it, I forgot to add the code to stop the 5-minute interval after the new version file was available and downloaded.

I’m sorry but it’s exactly cases like these that should be covered by some kind of test, especially When diving into a refactor. Admittedly it’s nice to hear people share their mistakes and horror stories, I would get some stick for this at work.

mcoliver · 1d ago
> Add special signals you can change on your server, which the app will understand, such as a forced update that will install without asking the user.

Ummm no. Even after this they haven't learned. Auto update check on app load and prompt user for download/update.

charlie0 · 1d ago
I wonder if that line of code was vibed.
zelon88 · 2d ago
> As a designer, I value the experience product I create provides to the users. And this was not even a bad experience; it was actually harmful.

$229 per year on a closed source product and this is the level of quality you can expect.

You can have all the respect for users in the world, but if you write downright hazardous code then you're only doing them a disservice. What happened to all the metered internet plans you blasted for 3 months? Are you going to make those users whole?

Learning from and owning your mistake is great and all, but you shouldn't be proud or gloating about this in any way, shape, or form. It is a very awkward and disrespectful flex on your customers.

Fokamul · 2d ago
Did you see? It's "Designed for macOS" I would put premium edition for 3999$ at least.
loeg · 1d ago
We've had single characters cost, you know, millions of $. (If you're familiar with C++ and the auto keyword, it's relatively obvious why that character is "&".)
arm32 · 1d ago
This is SUCH an Electron moment!
codeulike · 2d ago
This 'single line of code' headline trend is dumb. Of course a single line of code can fuck everything up, code is complicated and thats how it works. Its not knitting.
watusername · 2d ago
Needs (2023) in the title.
jer0me · 2d ago
(2023)
silverfrost · 2d ago
In other news a screen recorder app is a 250MB (presumably compressed) download...
zveyaeyv3sfye · 2d ago
FWIW, OBS is ~150 MB, not an electron app and actually open source.

https://obsproject.com/

meta87 · 1d ago
rookie numbers
coip · 1d ago
wonder why they're not making use of the ETag header
gitroom · 1d ago
Honestly, that's a rough one. I've written dumb bugs like that before, cost nowhere near $8k tho lmao. Kinda makes me extra paranoid about what my code's actually doing in the background.
ForOldHack · 1d ago
Obligatory: "You are not expected to understand this:" -Dennis Ritchie
ForOldHack · 1d ago
Just $8000?

A giant ship’s engine failed. The ship’s owners tried one ‘professional’ after another but none of them could figure out how to fix the broken engine.

Then they brought in a man who had been fixing ships since he was young. He carried a large bag of tools with him and when he arrived immediately went to work. He inspected the engine very carefully, top to bottom.

Two of the ship’s owners were there watching this man, hoping he would know what to do. After looking things over, the old man reached into his bag and pulled out a small hammer. He gently tapped something. Instantly, the engine lurched into life. He carefully put his hammer away and the engine was fixed!!!

A week later, the owners received an invoice from the old man for $10,000.

What?! the owners exclaimed. “He hardly did anything..!!!”.

So they wrote to the man; “Please send us an itemised invoice.”

The man sent an invoice that read:

Tapping with a hammer………………….. $2.00

Knowing where to tap…………………….. $9,998.00