SmartQA Community

COVID19 and Clean Code Part 1: Techniques

T Ashok (ash_thiru on Twitter)

Summary

Corona virus aka COVID19 is a global talking point now. What is being done to contain the COVID19? Well, there are THREE actions in terms of Prevention, Detection, Containment being aggressively pursued. Three targets of young children, old people and sick persons are the most vulnerable as of now. In this article we take a look at the actions being taken to contain the pandemic and relate to what to do deliver clean code.


Corona virus aka COVID19 is a global talking point now. A pandemic now, it has shaken the entire population of the world, busted the business and the world economy. The major stock markets are taking a massive beating driven by the sentiment that there is no medicine for this as of now.

Interestingly the suggestions posed by experts are pretty basic stuff related to good hygiene and this seems to be the only way to go given that there is no medicine as of now.  What can we learn from COVID19 to deliver clean code?

So what is being done to contain the COVID19? Well, there are THREE actions in terms of Prevention, Detection, Containment being aggressively pursued. Three targets of young children, old people and sick persons are the most vulnerable as of now.

What is being done in terms of PREVENTION that we can relate to code?

  1. Cover when you sneeze/cough => USE ASSERTS, HANDLE EXCEPTIONS
  2. Wash hands frequently => SIMPLIFY, REFACTOR
  3. Don’t touch surfaces => STRIVE FOR LOW COUPLING

What is being done in terms of DETECTION that we can relate to code?

  1. Check for fever => DO BASIC TESTS
  2. Check for other symptoms =>  USE SMART CHECKLISTS, DO DETAILED TESTS
  3. Check if contact with affected => DO STATIC CODE ANALYSIS
  4. Check origin on arrival (for travellers) => WRITE DEFENSIVE CODE
  5. Check travel history => ANALYSE CODE COVERAGE

What is being done in terms of CONTAINMENT that we can relate to code?

  1. Quarantine affected/suspected persons => REWRITE POOR CODE, DON’T FIX
  2. Use masks use asserts/ EMBED TESTABILITY
  3.  Publish routes travelled by affected people => PUBLISH CHANGE LOGS SO THAT OTHERS MAY ASCERTAIN IMPACT, CREATE INTERACTION MAPS, REGRESS CODE

Now who are the TARGETS that could be most impacted in COVID19  that we can relate to code?

  1. Young children => NEW CODE
  2. Old people => OLD CODE WITH MINIMAL DOCUMENTATION/CK COMMENTS
  3. Sick people => CODE FRAGMENTS THAT HAVE BEEN BUGGY

Here is the entire learnings summarised in the full mind-map.

Check out the current article COVID19 and Clean Code Part 2 : Process & Criteria,
that outlines techniques to deliver Process & Criteria, inspired by Covid19.


#55 – COVID19 & Clean code

SmartQA Digest

Corona virus aka COVID19 is a global talking point now. What is being done to contain the COVID19? THREE actions in terms of Prevention, Detection, Containment being aggressively pursued keeping in mind that the three targets of young children, old people and sick persons are the most vulnerable as of now. In this week’s article “What can we learn from COVID19 to write clean clean code” we take a look at the actions being taken to contain the pandemic and relate to what to do deliver clean code.
 
This week’s SmartBites video is a lovely video on “Delivering Clean Code #1” from Raja Nagendra Kumar. This week’s smartbits is on “How to reduce waste(bugs)” by Tathagat Varma. 
 
“Building new hospitals/ shelters alone is not adequate, it needs to be complemented by community strategies, such as limiting group activities, and personal hygiene practices” says Winnie Yip, Harvard University. In the same vein, testing alone is not enough, clean code practices need to be installed for SmartQA is what this week’s poster says!

beEnriched

expandMind

Black box thinking

Learning from failures .The inside story of how success really happens and how we cannot grow unless we learn from our mistakes.

Read More »

SmartBites

||VIEWS FROM INDUSTRY LEADERS||

smartbits

||NUGGETS OF LEARNING||