Very early on in his life, while on lengthy voyage from London to Philadelphia, Ben Franklin created a system of thirteen virtues to live his life by. He spent the remainder of his days giving special focus to one virtue per week in a 13 week cycle, as well as noting the virtues he failed to live up to at the end of each day.
Over time he credited the system with making him more productive and more fulfilled.
My aspirations are not so lofty, but in the spirit of the new year, I present Ben's thirteen virtues as they relate to code review and discussion. Nothing here is meant to be taken as gospel, but together they give me a path towards the type of collaboration we value at Jane Street.
My simple hope is to waste less time, produce better code, and have fewer arguments over the next 12 months than I did over the last.
Review thoroughly, but not to the point of exhaustion. Be mindful of the limits of review.
Say only things that clearly benefit the code; avoid trifling comments and tangents.
Create the structure (files, modules and types) necessary to give every concept a clear place. Be suspicious of catchall modules.
Respond to feedback and change requests quickly. Momentum is important.
Don't waste people's time with frivolous review, careless comments, or code that isn't ready for review. Attention is expensive.
Prefer to respond with working code over additional commentary. Focus review on immediately productive outcomes instead of uncertain concerns.
Come to discussions with an innocent mind. Engage in code review with the clear goal of helping.
Weigh code decisions on the evidence at hand today, and not on personal preferences, prejudices, or obsolete past constraints.
Avoid extremes in both style and approach. Incorporate strong views slowly.
Spend time to lay out code in a clear and visually pleasing way. When reviewing, leave the code neater than you found it.
Don't become impassioned or incensed over trifles. Engage in all conversation with an open balanced tone and a sense of patience.
Proliferate new ideas through the code base cautiously and be aware that even a good idea may not work in all places.
Take a modest view of your own contributions and feedback. Be unpretentious and respectful in your comments. Accept that you may be wrong.