Employee onboarding goes quickly and smoothly and complex projects are something that we look forward to. Our programmers are continually expanding their knowledge, also beyond their area of expertise. On a considerable part, it’s because we implemented the practice of doing a code review in our projects.

CODE REVIEW – how does it work?

What is code review?Once a programmer completes their assigned task, he or she makes a merge request. It is then visible in the web interface for everyone in the project. Then, each line of code can be put under analysis and commented on. Such a comment is an invitation to a discussion in which each team member can participate.

The discussion ends when team members come to an agreement, and somebody marks it as ‘resolved’. Of course, if a remark doesn’t leave room for discussion we can make the change straight away. Sometimes it may be, that there is no need for the discussion.

Code review’s goals

  • Code review praxis allows checking whether the overall conventions have been kept.
  • It simplifies the analysis of the architectural correctness and helps to spot any mistakes.
  • It helps to notice and eliminate bugs and issues that might cause problems in the future.

The main goal of doing a code review is to improve the quality of the code. We can prevent, that the unverified issues will come out of the blue when we put the code through further modifications. However, there is a huge benefit that also comes from it. We mean – the exchange of knowledge between programmers of different experiences and educational backgrounds. As a result, it becomes a platform for such exchange and supports personal development.

When code review is vital

The truth is that doing a code review is almost always beneficial. However, it’s especially useful when either someone new is joining the team or a project is extensive and requires much time. A new employee or a team member might need guidance. So the introduction to the used style guide and the way of work is highly recommended. Such an introduction goes smoothest in practice, while working, thus through a code review.

A ‘better’ code

The key of code review is a better codeDoing a code review allows the team to create a ‘better’ code by correcting one another and continually introducing changes.

It challenges everyone involved to see the possibilities that lie in front of them and the room for improvement. As a result, the finished product is of much higher quality and standards.

Sharing knowledge

Code review helps to share knowledge

Doing a code review creates a platform for the exchange of knowledge about software development. However, it doesn’t necessarily mean that only those more experienced can correct the code of  younger, less experienced programmers.

At WEBSENSA, it is encouraged that each person assigned to a particular project can put forward their suggestions.

They can question other’s actions, and discuss the approval of a CL. (CL stands for “changelist”, which means changes in the code implemented by a given merge request.) This attitude is necessary to create a solid ground for an honest and smooth flow of information. Furthermore, it makes it possible for each team member to improve their skills and widen their knowledge while working on projects. 

Experience

Getting a code review from senior programmers is an excellent opportunity to broaden your skills. When joining the WEBSENSA team, you start your project work straight away. Code review improves professional experienceExperienced reviewers make the onboarding process more comfortable. They help you quickly adapt to the working atmosphere and introduce you to our means of work.

Those with smaller experience have an opportunity to learn more about a language, software design principles, and its general architectonic structure.

Furthermore, when new and experienced coders are joining a team, it creates a perfect opportunity for a junior programmer. He can become the reviewer for the new person and acquire more skills. Primarily, seeing the code of a senior programmer, they can broaden their technical skills. Additionaly, they gain the chance to learn how to review code.

Team-work

Team-work in IT projectWorking on creating a well-designed code with a team is the purpose of a code review. Instead of pinpointing the mistakes of other coders, it encourages collaboration. Everyone must be able to admit their mistake and prioritize the improvement of code health over their ego. It applies to those both with bigger and lesser experience in the field. Creating a ‘grading’ culture can be highly discouraging. Those with lesser experience can feel like they are presenting their work to be judged.

Instead of pinpointing the mistakes, code review encourages collaboration.

So there is an important rule that we should obey to make reviewing a code smooth and conflict-free. The reason for commenting on CL needs to be always based on technical facts and not on personal opinions. The willingness to cooperate and understand each other’s intentions is vital in the process of code review.

Code review in IT projects

To sum up, code review allows seeing how the programming process progresses with time. It shows all the introduced steps in order, and how the new features might affect its functionality. Furthermore, it shows how dynamic the entire process is and how well the team cooperates. However, you have to remember that nothing is perfect, especially in the case of such tedious work as writing programming code;) That’s why the primary purpose of a code review is to create not a perfect but a ‘better’ code.

If you are interested in other ways of co-working in IT companies like WEBSENSA, be sure to subscribe to our newsletter below. We will inform you about the newest articles that may interest you!