The Gods of the Copy Book Headings Frowned Upon Me
So yesterday, I pushed out a new FRK.
You could say I FRKed up, and you’d be right.
See, before I push stuff to master, I do a round of testing in our AWS lab to find version-specific bugs and make sure everything is at least compiling.
If the round of testing passes, I bump version numbers and merge the changes into the master branch.
Yesterday, I found a bug in sp_BlitzCache after bucketing some checks into version-specific sections. I did this to avoid unnecessary XML processing.
For example, versions of SQL Server prior to 2012 don’t have a NonParallelPlanReason in there, so I figured I’d save some CPU cycles by not looking for it. Trace Flags are also only in newer versions, so I added a version check for them too.
The error was that later on in sp_BlitzCache, we look at the #trace_flags table to provide information about which trace flags are enabled, and that select needed a version check, too. So I added that, bumped version numbers, and then…
Well, that didn’t make it to the master branch.
Until this morning.
After causing some grief for a user.
Eggy
The issue has been fixed, and everything has been updated and refreshed on our end. If you use older versions of SQL Server, and sp_BlitzCache, you’ll definitely want to download the update.
I’m looking at better ways to do the last round of testing and make sure this doesn’t happen again. If anyone out there has any Hot Git Tricks (aside from “pay attention, dummy”), leave a comment.
My Walk Of Shame continues.
4 Comments. Leave new
I applaud you! Not for that fantastic code, but for admitting and owning the mistake. This is an admirable trait that everyone needs to learn to do as we are not perfect. (I’ve seen folks sneak fixes in to correct the problem but never own up to it which causes problems when the user sees a mistake that magically gets fixed by downloading or trying again.)
I appreciate it. Still stings to mess up, but I’m still learning GitHub (which is slow, since I don’t use it a ton).
Just make Richie do it… He, i’m sure, LOVE the Hub of Gitting.
How do you do your AWS testing? Are you using Travis with Github? You should be able to automate your testing process and do unit tests every time a new commit is entered, and it’ll give you the green light on it’s own.
From that point forward, every time you find something that breaks a user, you just write a new unit test to make sure it doesn’t happen again.
See travis-ci.org