5 Bad Habits of Software Developers

Ilona Codes on August 10, 2019

There is no hard and fast rule as to how a programmer should program. So, there is nothing wrong if you have your own style of programming. There ... [Read Full]
markdown guide
 

On the topic of documentation, I'd say that using Doxygen or some other API autodoc tool is not the solution most people think it is. Useful documentation almost always has to be written by hand, otherwise it's like teaching someone to use a toaster by explaining the electrical specifications of the heating element.

Regard "night owls", I find that getting up earlier (5 AM for me) gives me time to ease into my day, get a bit of work done in the quietness of the early morning, and yet actually help my productivity for the rest of the day. Being an early bird or a night owl is a matter of choice and practice, not biology. You can decide what to be.

 

Waking up at 5 AM is more than just getting things done 👍

 

5AM huh? What time would you usually go to bed? I'd love to try this for myself.

 

Personally, 10pm. I typically only need about 7 hours of sleep to be well-rested. (Just to make up the difference, I sleep 10pm-7(:30)am on weekends.)

If you find you need 7.5 or 8 hours of sleep, you can shift the bedtime or wakeup times around, of course. This week, I've been unusually tired, so I've been doing 10pm-5:30am or 10pm-6am.

 

Agree with everything you said!

I can't believe there are people that think tests are pointless. If they hate tests so much, they can go and test every single feature for each change they make. That might change their minds 😂

 

Many thanks! Writing tests makes life easier for software developers 🙂

 

They believe they are so smart and so good that they can't possibly make a mistake and introduce a regression.

Moreover, when this happen, they'll blame everything around them, but not themselves.

 

Brilliant blog, I agree with it all. I particularly resonate with your chapter on staying up late and being a night owl, I used to be so bad with this, coding till the early hours. It wasn't until I read Why We Sleep by Mathew Walker that I actually started to realise the importance of sleep!

 

Thanks a lot for your words and the link! 🙏

 

Sleep is essential!!

First or all, It's a great article and I haven't finished it but have, on the others hand, saved it for later. The funny thing is, when you're younger you feel invincible and don't pay attention to your sleeping habits.

I belive this is especially prominent in software development community or maybe it's IT in general. I felt the need to comment since I've been doing dev for around 20 years, started when I was 16.

In the old days, I would sleep maybe 2 to 4 hours a day, and would stress myself to the point of almost collapsing.

After weeks of this torture, my body finally decided to put a stop to all this in a form of grand mall epileptic seizure. And there you have it.

If I hadn't been so reckless about my own health, my daily routine would not include taking two types of pills twice a day.

This is just my unfortunate experience and it doesn't happen to everyone but it could happen to you if you're not careful. Times have also changed, for the worse of course; now it's even more stressful and people are pushed to work even harder.

Go to bed before 2am, get at least 6 hours of sleep, it will increase your productivity and maybe spare you of any potential health issues.

Cheers,
DF

Check this great article:

 

There's an underappreciated difference between feeling productive and being productive. That's particularly true when you feel you're in the 'zone' (Uncle Bob himself discussed that point in The Clean Coder).

 

I have fucked a lot of people over not documenting things. There have been jobs where I had a bus factor of 1, and when I left I was being a self-centered ass. There were a lot of other things going on in my life at the time so I'm learning to forgive myself, but it's a lesson I have taken to heart.

 

Point 3, third paragraph, that could happen even when working on daytime. If you feel productive you probably are, though I agree on the point that we are design to live at day and sleep at night, plus the rest of the society also is. That's why is better to be productive during daytime.

Thanks for putting the time on this article.

 

Thank you for your thoughts! I am happy you liked the article.

 

I use Doxygen but that is low level documentation used primarily by developers. It's only useful in combination with a hand written higher level overview documentation. What's the point of knowing how a spark plug works if you don't know how to start or drive a car.

Also, it makes me cringe when I see stuff like "the code is self explanatory", etc.

I highly appreciate developers who take their time to write user level documentation, which is, in my opinion, vastly more useful than describing function arguments and return values.

LaTeX is my preferred tool for high level documentation, while Doxygen serves the purpose of being API documentation tool.

Regarding code style, I use ClangFormat since I'm a C developer. It's a great tool to keep your coding syle consistent. Another similar tools which I used while writing Web apps in React.js is Prettier; it is highly configurable and probably supports a plethora of languages.

 

Very glad you included testing as that for me is probably the most valuable. There have been plenty of times when a regression test has quickly saved me.

 

And thanks to test coverage now you are not afraid of changing code while refactoring or new feature implementation 🙌

 

Are tests not enough documentations? In addition I got lot of devs saying "well you wouldn't need test if you just code better and you'd code better if you understand every single little thing in the system like I did". :\

 

In my opinion, it should be basic documentation for the project with the project description + architecture, setup, run, and deployment. Truly understanding of the project comes during the work on it.

Some developers might be lazy to cover the software with tests and they are looking for excuses not to learn it 🙈

 

Guilty of point 3.

Also guilty for being loud in the office. I work in a scrum team and we are the loudest in the open space, not to mention arguing and throwing sexist jokes. I think that if my team had at least one female dev, we'd nicer to each other ;)

 
 
 

"Having a good test coverage encourages developers to make changes more confidently..."
How many % of the codebase should be covered with tests in your opinion?

 

It's not just a number.

It's also the importance. The more important the bit of logic (and the more other modules depend on it) the better it should be tested.

Looking at a single number is not productive because you can always increase coverage by adding more tests to not-so-important code.

 

To think you are the smartest person in the world sometimes becomes a bad habbit of developers also. 😏

code of conduct - report abuse