DEV Community

Cover image for The Unhinged Reality Of Engineering Part One: It Wasn’t The Lock
Khalid Elokiely
Khalid Elokiely

Posted on

The Unhinged Reality Of Engineering Part One: It Wasn’t The Lock

There is this quiet local coffee shop in my city - the very one I am writing this article from. It’s a very oriental place, soothing music, proper lighting and amazing Turkish coffee that I love. I also like to stay very hydrated, and trust me this is an important information.

Oh! It's important!

Because I like staying hydrated, I also tend to visit the restroom a lot for sweet relief.

Enter: The Privacy Lock

lock 2

The door’s old lock mechanism is a hook-and-eye latch lock system.

Consists of:

  • The base of the latch (The part bolted to the door)
  • The fish-hook bar (The long shiny bar connecting the door to it’s frame)
  • The eye catch (The golden part mounted on the frame)

And it works perfectly in theory. But, as shown, due to several factors like humidity - the placement of the eye catch causes the tension from the base of the latch to the eye catch to increase dramatically. Eventually slowly moving the bar up and unlocking itself.

And because I am very well hydrated, I tend to finish my business in more time than it takes for the latch to unhook itself. So, I’m presented with 2 solutions:

  • Finish fast before the bar unhooks
  • Hold the bar down while I’m finishing my business.

Both options are doable for a simple pee situation. But if I intend to use the restroom for something a little more tedious, these 2 solutions become notoriously unacceptable.

The Zero-Spend Culture

Because I pay this restroom a lot of visits during the day - sometimes I look and wonder at the fixes the workers deploy to this lock mechanism.

Sometimes it’s jamming a small paper or cardboard in the eye to create friction. But this fails a lot and requires constant reapplication because the jammed filler falls or becomes wet quickly.

I politely asked one of the workers why not just change the lock. Their response was:

The owner doesn’t want to spend money on a new lock or risk having to replace the door.

The Zero-Spend FIX

I thought to myself. These kind of cardboard patches are oddly familiar.

It’s the kind of fix that engineers deploy when production is burning, things are breaking, and the client doesn’t want to spend resources on a proper overhaul. It is the equivalent of buying a bigger server instead of fixing the query. It fixes the symptom, but not the problem.

I stopped one time to think. What would it take to fix this automatic unhooking problem without spending money on a new lock.

If you look closely, the issue isn't friction. It's geometry. The base of the latch is mounted visibly higher than the eye catch. Because the bar tilts downward (diagonally from the base of the latch to the eye catch), any tension on the door doesn't just pull sideways it pulls diagonally upward. It acts like a tiny elevator, slowly lifting the hook bar out of the socket.

Once you see the root cause, the solution is obvious: move the eye catch up a few centimeters.

By re-mounting the eye catch so it's perfectly level with the base, the bar in locked position sits completely horizontal. The tension now only pulls sideways, meaning the door can never lift the hook on its own.

This fix can be deployed in under 5 minutes. It doesn’t just patch the problem with fillers; it permanently fixes a high-stakes problem with minimum to no spend.

The Tech Debt Reality

Every engineer faces a problem like this at least once in their career. It’s what inherently creates tech-debt.

We all know tech debt is bad. This is not a claim this article is trying to make.

The question is how often does the team culture allow thinking in terms of: Is the entire solution precisely suitable to the problem but poorly optimized or implemented?

rather than: How many more components can we add to the solution so it stops breaking? disguised as an elegant engineering fix.

The Reality of Today

There is a problem. The workers recognize it enough to patch it with fillers in the eye of the lock. And I will continue having my coffee.

Stay hydrated.

Top comments (0)