{"id":471,"date":"2019-01-11T15:13:00","date_gmt":"2019-01-11T14:13:00","guid":{"rendered":"http:\/\/www.labo.mathieurella.fr\/?p=471"},"modified":"2020-06-28T15:18:58","modified_gmt":"2020-06-28T13:18:58","slug":"questions-to-ask-yourself-when-conducting-a-code-review","status":"publish","type":"post","link":"https:\/\/www.labo.mathieurella.fr\/?p=471","title":{"rendered":"Questions to Ask Yourself When Conducting a Code Review"},"content":{"rendered":"\n<p>Here are some of the questions we may ask ourselves while reviewing code.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"is-the-code-clean-and-modular-\">Is the code clean and modular?<\/h4>\n\n\n\n<ul><li>Can I understand the code easily?<\/li><li>Does it use meaningful names and whitespace?<\/li><li>Is there duplicated code?<\/li><li>Can you provide another layer of abstraction?<\/li><li>Is each function and module necessary?<\/li><li>Is each function or module too long?<\/li><\/ul>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"is-the-code-efficient-\">Is the code efficient?<\/h4>\n\n\n\n<ul><li>Are there loops or other steps we can vectorize?<\/li><li>Can we use better data structures to optimize any steps?<\/li><li>Can we shorten the number of calculations needed for any steps?<\/li><li>Can we use generators or multiprocessing to optimize any steps?<\/li><\/ul>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"is-documentation-effective-\">Is documentation effective?<\/h4>\n\n\n\n<ul><li>Are in-line comments concise and meaningful?<\/li><li>Is there complex code that&#8217;s missing documentation?<\/li><li>Do function use effective docstrings?<\/li><li>Is the necessary project documentation provided?<\/li><\/ul>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"is-the-code-well-tested-\">Is the code well tested?<\/h4>\n\n\n\n<ul><li>Does the code high test coverage?<\/li><li>Do tests check for interesting cases?<\/li><li>Are the tests readable?<\/li><li>Can the tests be made more efficient?<\/li><\/ul>\n\n\n\n<h4 class=\"wp-block-heading\" id=\"is-the-logging-effective-\">Is the logging effective?<\/h4>\n\n\n\n<ul><li>Are log messages clear, concise, and professional?<\/li><li>Do they include all relevant and useful information?<\/li><li>Do they use the appropriate logging level?<\/li><\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Here are some of the questions we may ask ourselves while reviewing code. Is the code clean and modular? Can &#8230;<\/p>\n","protected":false},"author":1,"featured_media":472,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/posts\/471"}],"collection":[{"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=471"}],"version-history":[{"count":1,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/posts\/471\/revisions"}],"predecessor-version":[{"id":473,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/posts\/471\/revisions\/473"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=\/wp\/v2\/media\/472"}],"wp:attachment":[{"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=471"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=471"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.labo.mathieurella.fr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=471"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}