I wasted days automating a 5-minute task
Leonard Tibben
—
Engineering

Written by
Have you ever thought about how much time you spent automating tasks? As developers, we can have quite complicated workflows. Programmers hate doing the same task twice. And have the power to control the most powerful tool in the world, the computer. So why not use that power to automate as much as we can?
My opinion is mostly informed by my experience as a flutter developer. Specifically with everything surrounding the actual flutter/dart development process, like CI/CD and versioning.
How much time are you really saving?
When automating a task, it is worth it to really sit and think about the time savings calculation. Let's say you have a 5 minute task that you do every month, if you spend more than 5 hours automating it, you won’t save any time over a 5 year period! I will include a very helpful xkcd comic that demonstrates this. I made this exact mistake with the deployment of my flutter app (I wish I could show it to you, but it's not public yet. Instead, check what we did with Flutter for Waste Vision). Building and uploading your flutter app to the Google Play Console or Appstore Connect is literally a 5 minute task. I have spent countless hours fighting with fastline and XCode cloud. Fastlane, I’m sure, is a really powerful tool if you know how it works. As a junior dev I already had my hands full trying to grasp how StreamControllers actually work. This just added too much complexity to my tech stack. When it worked it was very fast indeed, but maintaining it and fixing it when stuff broke down took more time than I got back. Same goes for Xcode cloud. When you do everything exactly the Apple way, it is a breeze. But try to color outside of the lines just a bit, like building a flutter app instead of developing a native iOS app in swift, and things become much more complicated.
You must understand that automating things often does not mean “setting and forgetting”. In my experience, more often than not you are simply spending time maintaining your automation instead of doing the thing you are automating.
Unnecessary dependencies
Automating a part of your workflow can come at the cost of increasing your dependency on 3rd party tools. I attempted automating versioning in my flutter app. The idea was to have a github action that uses the ceder package to automate semantic versioning. Again, a 30 second task that you do easily on every PR. It took me a whole day of fighting github actions to come to the same conclusion that this task is better left unautomated. Even if it did end up saving me time in the end (which couldn’t be more than a few minutes a month), I don’t want the added anxiety of relying on a 3rd party package and a whole new github action to maintain.
It keeps you sharp
This is harder to quantify but I find doing tasks like these manually gives me a better feeling of what's going on in my project. I’ve got a better sense of points of failure and things that should be refactored in the near future this way. Automation can give you the illusion that your code base is good just because the automation succeeded.
Some things need a human touch too. Semantic versioning is, by definition, semantic. When is something a patch, feature or major release? I believe there is no clear answer. And automation definitely doesn’t solve this issue. Let's say you and your coworker both have different ideas about semantic versioning and you run into a version clash. Automating this task doesn’t take away the human error aspect of this problem, but now you have the additional problem of not remembering which PR you bumped to which version, because it was all automated away. When you do tasks like these manually they force you to think about the decisions you are making. I believe this prevents problems in the future, and if they do arise, makes them easier to solve.
Concluding
My message to you is: Do something manually a few times before you try to automate it. Automation can be great in the right situation. But you often overestimate the need for it.




