I try and follow a rule when writing: If the sentence contains the conjunction "and" I see if I can split the sentence into two, or more sentences. An "and" indicates that I am trying to convey more than one aspect/purpose of an idea in the sentence.
I am an advocate of intentional naming. Intentional names can result in long names. If a function name contains an "and", it is an indication that the function is intended to do more than one thing. It breaks the rule that a function should "do only one thing and do it well" - also known as the Hedgehog Principle.
Showing posts with label Coding Smells. Show all posts
Showing posts with label Coding Smells. Show all posts
11 February 2017
27 September 2010
Lessons from the Commonwealth Games: Hygeine
Lalit Bhanot, of the Organizing committee is reported to have said that our sense of hygiene differs from that of the other nations participating in the games. Some people, not unexpectedly, have been offended by that.
Let us take it that Mr. Bhanot was not taking of personal hygiene but rather of public hygiene. It would not surprise me if even that was contested by people responsible for public hygiene. I am sure they could come up with certificates that say that public hygiene is world class. It would surprise many that Noida has an ISO 9001 certification.
Certification is a one-off, or at best annual, event. A process has to be lived 24 x 7.
Bad hygiene, private or public, usually manifests itself as a bad odour. Bad code "hygiene" too usually manifest themselves as coding smells.
AntiPatterns are very closely related to coding smells.
Many years ago, acmet's Tools BU was confident it was doing good work for its Japanese customer. There was a regular flow of defects coming in, but the customer was not complaining about quality. Being Japanese they would have considered that rude. They hinted. We did not get the hint. One day the customer could not stand the "smell" any longer. They told us bluntly. That is when we started to improve our software development hygiene.
The regular flow of defects was a process anti-pattern that we failed to sniff (I apologize for mixing metaphors:-). As with personal hygiene, most times there will be no clear message for bad process hygiene. Learn to read the small tell-tale signs. Be paranoid.
Lessons
Get QA and developers to sensitize their noses to detect project and coding smells.
Certifications breeds smugness. Live the process 24 x 7.
Let us take it that Mr. Bhanot was not taking of personal hygiene but rather of public hygiene. It would not surprise me if even that was contested by people responsible for public hygiene. I am sure they could come up with certificates that say that public hygiene is world class. It would surprise many that Noida has an ISO 9001 certification.
Certification is a one-off, or at best annual, event. A process has to be lived 24 x 7.
Bad hygiene, private or public, usually manifests itself as a bad odour. Bad code "hygiene" too usually manifest themselves as coding smells.
AntiPatterns are very closely related to coding smells.
Many years ago, acmet's Tools BU was confident it was doing good work for its Japanese customer. There was a regular flow of defects coming in, but the customer was not complaining about quality. Being Japanese they would have considered that rude. They hinted. We did not get the hint. One day the customer could not stand the "smell" any longer. They told us bluntly. That is when we started to improve our software development hygiene.
The regular flow of defects was a process anti-pattern that we failed to sniff (I apologize for mixing metaphors:-). As with personal hygiene, most times there will be no clear message for bad process hygiene. Learn to read the small tell-tale signs. Be paranoid.
Lessons
Get QA and developers to sensitize their noses to detect project and coding smells.
Certifications breeds smugness. Live the process 24 x 7.
Subscribe to:
Posts (Atom)