Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Code Reviews
Search
Janos Gyerik
October 14, 2015
Programming
0
150
Code Reviews
Just Do It!
Janos Gyerik
October 14, 2015
Tweet
Share
More Decks by Janos Gyerik
See All by Janos Gyerik
Capture The Flag at SonarSource 2019
janosgyerik
1
44
Keyboard shortcuts
janosgyerik
0
140
Analyze your changeset in a branch before git push using SonarLint + Git hooks; Round #2
janosgyerik
0
650
Analyze your changeset in a branch before git push using SonarLint + Git hooks
janosgyerik
0
360
Unwatch GitHub repos
janosgyerik
0
320
Playing with Yahoo! Pipes
janosgyerik
0
260
Cool features of GitHub
janosgyerik
0
1.3k
Time-saving tricks on the command line
janosgyerik
1
4.3k
Other Decks in Programming
See All in Programming
条件判定に名前、つけてますか? #phperkaigi #c
77web
2
760
Angular-Apps smarter machen mit Gen AI: Lokal und offlinefähig - Hands-on Workshop!
christianliebel
PRO
0
130
AI活用のコスパを最大化する方法
ochtum
0
290
20260228_JAWS_Beginner_Kansai
takuyay0ne
5
610
How to stabilize UI tests using XCTest
akkeylab
0
140
Feature Toggle は捨てやすく使おう
gennei
0
300
モックわからないマン卒業記 ~振る舞いを起点に見直した、フロントエンドテストにおけるモックの使いどころ~
tasukuwatanabe
3
420
The free-lunch guide to idea circularity
hollycummins
0
330
ベクトル検索のフィルタを用いた機械学習モデルとの統合 / python-meetup-fukuoka-06-vector-attr
monochromegane
2
510
Pythonデータ分析コトハジメinFukuoka
kanan
0
100
Symfony + NelmioApiDocBundle を使った スキーマ駆動開発 / Schema Driven Development with NelmioApiDocBundle
okashoi
0
210
最初からAWS CDKで技術検証してもいいんじゃない?
akihisaikeda
4
170
Featured
See All Featured
Measuring & Analyzing Core Web Vitals
bluesmoon
9
790
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
200
Ethics towards AI in product and experience design
skipperchong
2
240
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
240
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
150
Reality Check: Gamification 10 Years Later
codingconduct
0
2.1k
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.2k
BBQ
matthewcrist
89
10k
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
64
52k
Exploring anti-patterns in Rails
aemeredith
2
290
Music & Morning Musume
bryan
47
7.1k
Transcript
code.reviews Janos Gyerik correct clean efficient tested efficient efficient clean
clean tested tested correct correct correct tested correc orrect correc tested efficient clean
2 what is it?
3 commit commit commit review commit commit review commit accept
commit commit commit NOT code reviewed code reviewed
4 why do it?
5 UCXGVKOG catch early catch early catch early bugs bad
patterns ugliness
6
7 peer review peer pressure
8 anything that gets reviewed gets better
9 quality time savings cost savings FACT
10 correct readable efficient tested buggy messy crappy untested NOT
code reviewed code reviewed
11 information sharing NO MORE bottleneck developers
12
13 why/when NOT do it?
14 big bang development too hard to control should be
the exception, not the norm! code reviews are not practical when…
15 without supporting tools tools help doing code reviews efficiently
don’t waste your time, get them and use them! code reviews are not practical…
16 what’s required? disciplined commits
17 incremental changes small and stable logical steps at all
levels
18 one feature one purpose one branch feature
19 short-lived max 3 days feature
20 (example good branch)
21 (example bad branch)
22 one commit one logical change
23 one good commit == stable build; related changes; no
garbage; small; good comment
24
25 (example good commit)
26 example bad commit with many changes)
27 (example bad commit with garbage)
28 how to do it?
29 git fetch origin master git checkout -b feature-x origin/ma
# work work work git commit git commit git push origin feature-x # create merge request
30 Create Merge Request create; don’t assign! self-review: any WTFs?
ready? assign!
31 peer review peer pressure
32 what to review?
33 readable is it clear? easy to read? easy to
understand? FACT Code is read far more often than written!
34 correct is the logic sane? does it work? bug
suspects? -> ask!
35 efficient any performance concerns? -> ask!
36 tested unit tests included? unit test opportunities?
37 good practices Code Complete Effective Java Sonar/Findbugs/… codereview.stackexchange.com
38 how bad can it be?
39 how in-depth? •not too much •not too little •just
right •DO IT FAST
40 attitude?
41 a code review is… NOT about the developer it
is about the code
42 don’t just say something is “wrong” suggest a better
way
43 the focus is.. NOT on problems it is on
solutions
44 perfect code? don’t seek perfect seek good enough better
is good enough don’t be a pain in the ass be flexible be constructive
45
46 mistakes… it’s OK to make mistakes it’s NOT OK
to not learn from them
47