{"id":1249,"date":"2013-04-12T12:45:49","date_gmt":"2013-04-12T02:45:49","guid":{"rendered":"http:\/\/brnz.org\/hbr\/?p=1249"},"modified":"2013-04-12T12:45:49","modified_gmt":"2013-04-12T02:45:49","slug":"bugs-of-the-day-2013-04-11","status":"publish","type":"post","link":"https:\/\/brnz.org\/hbr\/?p=1249","title":{"rendered":"Bugs of the day, 2013-04-11"},"content":{"rendered":"<h2>Don&#8217;t delete code that does things<\/h2>\n<p>I got carried away <a title=\"Compiler-assisted code cleaning, Thursday 2013-03-28\" href=\"https:\/\/brnz.org\/hbr\/?p=1197\">while deleting some code<\/a> that didn&#8217;t do anything and accidentally removed some parts that did do things &#8212; function calls with side effects that I didn&#8217;t fully understand. I make the same kind of change later to a different part of the codebase and got it right there. I didn&#8217;t think to go back and look for the possibility of this problem in my earlier change.<\/p>\n<p>This one got checked in and caused problems for others later. It would have been caught by better testing on my part. (I&#8217;m convinced that I did test this and saw no problems, so either I didn&#8217;t actually test a build with the change or I my testing wasn&#8217;t really testing of the code affected)<\/p>\n<h2>Unravel the whole garment<\/h2>\n<p>In a related deletion, I managed to break another piece of code connected to one that I was modifying. I broke one of the assumptions of the other piece of code, which was far less obvious to me because they interacted via a mechanism that I was not familiar with.<\/p>\n<p>Again, this would have been caught by better testing on my part.<\/p>\n<p>My apologies to those affected. Clearly, I suck.<\/p>\n<p>(On the upside, I&#8217;ve now learned a little bit more about another part of the codebase. This is a good thing.)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Don&#8217;t delete code that does things I got carried away while deleting some code that didn&#8217;t do anything and accidentally removed some parts that did do things &#8212; function calls with side effects that I didn&#8217;t fully understand. I make the same kind of change later to a different part of the codebase and got &hellip; <a href=\"https:\/\/brnz.org\/hbr\/?p=1249\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Bugs of the day, 2013-04-11&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[26],"tags":[],"_links":{"self":[{"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/posts\/1249"}],"collection":[{"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1249"}],"version-history":[{"count":4,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/posts\/1249\/revisions"}],"predecessor-version":[{"id":1253,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=\/wp\/v2\/posts\/1249\/revisions\/1253"}],"wp:attachment":[{"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1249"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1249"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/brnz.org\/hbr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1249"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}