I haven’t been writing about my contributions for a while, so this post will try to catch you up.
The start of my recent spree was “Path string roundup”. This was a round-up PR because it looks for some set of patterns across the code-base, and replaces them with something else.
Here’s what I think about round-up PRs…
To write round-up PRs it takes:
- Time cost – high
- Very rarely does Find/Replace do the job
- Since in order to make them easy to review, you have to put each type of substitution in its own commit, you end up jumping between files a lot so you can’t work in flow when you see some other change that needs to be made.
- Mental effort – low
- Usually it’s easy to tell whether or not the pattern applies.
- Conflict resolution effort – high
- Since they touch many places in the code-base, there are often conflicts.
To review them it takes:
- Time cost – medium
- Lots of changes but not a lot of time spent on each
- Mental effort – very low
- Assuming that each type of change is in its own commit, you don’t have to think almost at all about the change.
- Note that this is only true in strongly typed languages where it wouldn’t compile if something trivial was wrong.
- Assuming that each type of change is in its own commit, you don’t have to think almost at all about the change.
Notably, I was motivated to write this specific round-up PR by an issue that a team member opened, implying to me that this was something the team wanted to have happen.
I feel frustrated about this PR because it has now been exactly two months (Sep 8 – Now) and with only positive response, it still hasn’t been merged.
At the same time, I respect that the team has higher priorities than code-quality (i.e. shipping before the two week from now deadline), so I understand why it has taken this long 🙂