I just hit the kill switch on my own app…

🚀 Road to 1,000,000 #Votap users — Day 65 | Current: 1348

I just hit the kill switch on my own app…

And honestly… every app should have this.

Right after pushing the new update, I wanted to test it like a normal user.

Very soon I spotted a bug. Because of a concurrency issue, some users who already had a username assigned could sometimes see the picker again… and sometimes not.

That’s the worst kind of bug.

It works.

Until it doesn’t.

Completely random. Pure “luck” depending on what runs first.

So I didn’t risk it. I flipped the app into maintenance mode. Everyone sees a simple screen, no interaction, until it’s fixed. Not fun… but way better than letting users run into broken logic.

I always knew I’d mess something up eventually 🤣

This time it was concurrency.

If you’re building an app — have a kill switch.

You’ll thank yourself later.

Fix is already in app review.

Download Votap in the App Store if you want to try it out.

More tomorrow.

274 views

Add a comment

Replies

Best

Flipping to maintenance mode is basically prioritizing data integrity over uptime, which is usually the right trade-off.

 Agreed. Fortunately in my case it just meant that people could choose a different username multiple times... So not an app breaking bug but still felt right to not "confuse" people and making the app unavailable for a while.

  Yeah that's fair. Sound like you made the right call given the uncertainty.

Even small inconsistencies like that can quietly erode trust, so I get why you preferred a clean pause over letting it behave "mostly fine."

How often do you test as a real user post-release?

All the time probably 3-5 times a day for my sanity 🤣

 curious how fast you can trigger it 🤔 is it instant from your side or does it depend on app store delays?

 I assume you mean the kill switch? It's instant. It has nothing to do with the App Store. I have implemented my own system into the app so I can set the flag on the backend and it propagates for all users. Same with forcing version updates.

How did you detect the bug so quickly?

fortunately this behaviour (showing a sheet with username picker) is evaluated everytime you get into the app after setting up the user profile. This was to catch existing users with no username yet + also new users. Since I open the app about 5 times a day to check if everything is stable, I came across it very fast.

Was this tied to async state handling?

Yes Fiona. I made a lazy mistake and had the setting up of the state variable determining showing the sheet with the picker in a different task then setting up the profile data. So sometimes if the eval went before the profile setup, it would show you the picker even though you had your username already.

I personally like this kind of fast decision-making. Shutting things down quickly is better than letting silent corruption spread.

Yes data corruption is my worst nightmare.

 Same here.

I respect that decision. I’ve learned the hard way that random bugs hurt more than downtime. Kill switch = sanity saver.

Did logs help pinpoint the issue quickly?

Well in this case it was very obvious and I pretty much had an idea about where it was before even opening the code. But yes they helped a lot too I use logging everywhere to help me debug those sequences.

Was there no way to return to the previous version of the app or to test the new version in a preview mode on the production server? So your user can still use the app while you fix the bug?

I think you might be able to temporarily pause the delivery of the new version. The problem was that I already had users on that new version.

I’ve pushed updates thinking everything was solid, then something random breaks. Concurrency issues are brutal.

Yes I will start caring about it way more. It is worth to spend more time on it.

What's your rollback if review takes time?

 That's a great question I just thought about that. Fortunately app reviews (for me) take usually no more than a day or two which seems to be no issue with about 1k users. Do you have any practical rollback strategies?

12
Next
Last