droidcon2013 facebook stewart
TRANSCRIPT
Mid !"#!: becoming native▪ “We were never able to get the quality that we wanted. Looking back, that’s probably
one of the biggest if not the biggest mistake [we made]”
http://www.flickr.com/photos/anandham/4499539060/2
Engineers committing mobile code
3
(but there are spoons)
There is no Android team
4
A developer’s day
5
Build
6
The working copy▪ We use git for source control
▪ Two branches we care about day-to-day:
▪ master
▪ stable
7
How the code is organized
Text
http://www.flickr.com/photos/darwinbell/3030214710/
8
▪ git checkout -b fancy_feature
▪ hack, hack, hack
▪ git commit -am ‘Fancy new feature’
▪ git rebase origin/stable
▪ hack, hack, hack,
▪ git commit -am ‘checkpoint’
▪ git rebase -i HEAD~!
▪ arc diff
9
Dependency injection
http://www.flickr.com/photos/31246066@N04/5253179784/
10
Test
11
Developers write tests
12
Unit tests
http://www.flickr.com/photos/aracelota/4773084433/
13
Larger tests
http://www.flickr.com/photos/amphalon/6510474165/
14
Commit
15
Code review▪ arc diff
16
Image macros
17
Arcanist▪ The command line counterpart to Phabricator
▪ arc lint
▪ Runs Android’s own lint tool
▪ Checks for common errors:
▪ Null pointers
▪ Using APIs unavailable in all supported Android versions
▪ arc land
▪ Pushes code into the tree
18
Buildbot
19
Dogfood
20
Gingerbread▪ Still incredibly popular.
▪ Some employees use a Gingerbread device
▪ Including our release manager
21
Updates▪ Employees use more recent version of the apps
▪ Rage shake to report bugs
http://www.flickr.com/photos/raindrift/7095238893/in/set-72157629492908038
22
Release
23
Pick two
Features, quality, schedule
24
Time based releases
Text
http://www.flickr.com/photos/andyhay/6947688734/
25
“Done” isn’t just native code▪ Design
▪ Release branch doesn’t take design changes, implies work isn’t quite ready
▪ Logging
▪ How do we know we aren’t regressing without data?
▪ Server-Side
▪ We need to test the interactions our users will see
▪ Privacy and Legal review
▪ Just as important as code review
26
Questions?
27