How not to run code reviews
-
Upload
victor-maliy -
Category
Internet
-
view
363 -
download
0
Transcript of How not to run code reviews
![Page 1: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/1.jpg)
How not to run Code Reviews
Viktor Malyi Software Testing Engineer
Garmin Würzburg GmbH, Germany
![Page 2: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/2.jpg)
2
Hallo!Software Testing Engineer Würzburg (Germany)
Earlier:Web-apps testing
Backend testingPerformance testing
iOS, Android apps testing
Leading testing teams
![Page 3: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/3.jpg)
3
What I do?
![Page 4: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/4.jpg)
4
Today
What do we think code review is?
What is code review in reality?
What to avoid?
What to pursue?
![Page 5: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/5.jpg)
5
Why doing Code Reviews?
Of course to find bugs!
![Page 6: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/6.jpg)
6
Other reasons for doing Code Reviews?
• To help• To teach/learn• Or to criticize?
![Page 7: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/7.jpg)
7
Code Review meetings
![Page 8: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/8.jpg)
8
„Over the shoulder“
![Page 9: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/9.jpg)
9
Remote reviews (tools-assisted)
![Page 10: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/10.jpg)
10
It’s not only about the code…
![Page 11: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/11.jpg)
11
Resistance to code review
![Page 12: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/12.jpg)
12
„Ego-Effect“
![Page 13: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/13.jpg)
13
Core Developers…
… get their reviews approved quicker*…
Impact of Developer Reputation on Code Review Outcomes in OSS Projects: An Empirical Investigation Amiangshu Bosu, Jeffrey C. Carver. Department of Computer Science, University of Alabama
![Page 14: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/14.jpg)
14
… and more often*Impact of Developer Reputation on Code Review Outcomes in OSS Projects: An Empirical Investigation
Amiangshu Bosu, Jeffrey C. Carver. Department of Computer Science, University of Alabama
![Page 15: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/15.jpg)
15
There is a problem
![Page 16: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/16.jpg)
16
You’re judged each time
![Page 17: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/17.jpg)
17
Do you feel that the code reviews you
do for other people are constructive
and clear?*
No 2 %
I don't know 31 %
Yes 67 %
*International online survey among IT-Professionals, November 2014, 310 participants
![Page 18: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/18.jpg)
18
Do you feel that code reviews
you do for other people have
been considered picky?*
No 21 %
I don't know 56 %
Yes 23 %
*International online survey among IT-Professionals, November 2014, 310 participants
![Page 19: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/19.jpg)
19
Why do you think your reviews are considered picky?*
*International online survey among IT-Professionals, November 2014, 310 participants
Not constructive and clear
“-1” numerous times
Too many emotions
Bad personal relations
0% 5% 10% 15% 20% 25% 30% 35% 40%
Multiple answers allowed
![Page 20: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/20.jpg)
20
Have you ever had a feeling that the one who reviews your code criticizes you personally and not your code?*
Yes 15 %
No 85 %
*International online survey among IT-Professionals, November 2014, 310 participants
![Page 21: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/21.jpg)
21
Which implications it has?
*International online survey among IT-Professionals, November 2014, 310 participants
Hard to get "+1"
0% 5% 10% 15% 20% 25% 30% 35%
Multiple answers allowed
Non-constructive and emotional comments
I have to wait for review too long
![Page 22: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/22.jpg)
22
Words can hurt
„Never do this in such a way!“
„Why it’s used here at all?“
„It’s all wrong!“
„WTF!?!“
„It’s obvious!“
![Page 23: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/23.jpg)
23
What to pursue?
![Page 24: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/24.jpg)
24
Ask questions rather than make statements
You did it wrong…
What was the reason of…
![Page 25: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/25.jpg)
25
Don’t ask „Why?“
Why the variable is not local?
It seems that the variable…
![Page 26: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/26.jpg)
26
Praise/Reward/Honour
Well done!
Good job! Let’s add this to our coding standards!
![Page 27: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/27.jpg)
27
Use code conventions
![Page 28: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/28.jpg)
28
Project-specific checklist
• Based on experience • Includes critical programming issues • Includes common mistakes • Great source for teaching newcomers
![Page 29: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/29.jpg)
29
Review less, find more
Smart Bear case study on informal code reviews, 2006, 2500 reviews, 3.2 MLOC, 50 developers
![Page 30: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/30.jpg)
30
Explain more first
Smart Bear case study on informal code reviews, 2006, 2500 reviews, 3.2 MLOC, 50 developers
![Page 31: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/31.jpg)
31
Reviews must identify as many defects as possible, regardless of personality who „caused“ or found them
![Page 32: How not to run code reviews](https://reader034.fdocuments.net/reader034/viewer/2022042716/55a663e61a28ab1e0e8b463e/html5/thumbnails/32.jpg)
32
PS
by SmartBear Software