How to use Poka-Yoke (Error Prevention) to improve the quality of software?

Tram Ho

Software engineering is a specialty aimed at producing high quality software through a planned and systematic approach to software development.

It adheres to standards to achieve a quality product. Software development has 3 main stages: analysis – design – implementation. Creating high-quality software is essential to producing an error-free product.

Error management

Errors are unexpected and unexpected behaviors that occur in the product. Anything related to errors is a process, not a specific state.

Finding and fixing bugs in the early stages of software development helps reduce time, work and money. Finding errors in later stages is always more time consuming than in the early stages. It helps improve quality by adding reliability, portability and maintenance, etc.

Therefore, companies are encouraged to go hand in hand with error management systems and error management stamps at every stage of software development to achieve good quality products and build customer trust. line.

One of the techniques to prevent errors is POKA-YOKE .

What is Poka-Yoke?

It is a quality assurance process introduced by a Japanese engineer named Shigeo Shingo. The term is used in the Japanese language as “Poka” means error and “Yoke” means prevention, ie Error or Error Prevention Technology.

The goal of Poka-Yoke is to develop processes to reduce errors by avoiding or early fixing bugs (designed to indicate user warnings or warning messages) during development and design phases. . This technique is mostly used in the manufacturing industry, but now the effectiveness of this technology is also applied to the software development processes quite well.

Examples of Poka-Yoke from a manufacturing industry

An example of a Poka-Yoke design from the manufacturing industry is – the SIM card slot in a mobile phone is designed in such a way that the user is allowed to insert the SIM card into the phone in the exact same way. Best. There will be no chance for users to make an error when inserting a SIM card into a mobile phone. This prevents (or resists) design errors.

Perhaps most people have already worked on installing a SIM card, right? Sure, we can’t get a SIM card into the phone if it’s not facing the right way =))

Examples of Poka-Yoke from software applications:

A perfect example of a Poka-yoke process in a software application is – Gmail’s file attachment feature.

When you enter the word ‘find attached’ while composing a new email and try to send the email but without attaching any Google files, it will show a popup reminding you that “you used the word” find attached “in the email but without any attached files, do you still want to email? ”

I have tested it and it is like that. How long has Gmail used to see this cool feature. Take a look at the image below

How does Poka-Yoke Technique work?

Steps to execute a Poka-Yoke process:

Here are some steps to design and execute a process to prevent software errors:

  1. List all user scenarios or end-to-end test cases of the application.
  2. Analyze all of these user scenarios by asking 5-whys to understand how these scenarios might fail.
  3. Once you can identify ways in which user scenarios may cause errors, design and apply a Poka-Yoke technique to avoid possible problems (For example, this design Could it be simply a simple Unit test to check if any of the functions that have been written are not working properly?).
  4. Make sure the technique is designed to prevent errors from working properly by giving errors or warning messages when the input data is incorrect or handling user scenarios.
  5. Once the trials are successful, add this technique to the list of Poka-Yoke processes to perform each time there is a new release / build.
    In the Unit Test example above, once the Unit test is written to test the code, check if it is working for positive and negative values. When these tests are successful, add them to the ‘Unit tests’ repository to execute whenever any changes are made in the relevant modules.
  6. Measure the success of Poka-Yoke processes. Check to see if this technique actually prevents or catches the error when it occurs.

Categories Of Poka-Yoke

  • Prevent the error
  • Error detection

Error prevention is the most important activity in the SDLC (software development life cycle). This method is used to identify all problems and actions needed to eliminate these problems. Many software errors can be prevented during the design phase itself.

Team QA can help prevent these errors by reviewing and evaluating software requirements documents. All issues identified at this stage are marked in the programming stages and prevented from occurring at later stages.

The examples in software engineering and manufacturing provided above are excellent examples of error prevention techniques.

Error detection is a common task for QA teams. QA teams use different methods and strategies to implement test cases effectively. Errors are detected by many other testing methods such as smoke test and Exploratory test.

What are the qualities of a good Poka-Yoke process?

  1. Poka-Yoke should be simple to create and maintain. It should also be easy to handle and cost effective. Maintaining a complex Poka-Yoke is time-consuming and often leads to problems if not properly maintained.
  2. Poka-Yoke should be designed early in SDLC to be able to spot problems quickly.
  3. A good Poka-Yoke process should be accurate enough to spot problems as they occur.
  4. A Poka-Yoke process should be designed in such a way that it can prevent most of the most common problems occurring in software.
  5. It should also be part of the programming and software design process.

Necessity of Poka-Yoke Technique in software design stage

To develop quality software, it is important that the design is based on user expectations. Users can use and process the software without making any costly mistakes.

Examples of Poka-Yoke in design and quality

# 1) An example of missing attachments while creating Gmail emails.

# 2) Some websites give warnings to indicate the strength / weakness of a user’s password. It also instructs the user to use a password strong enough that the password must contain both letters and numbers.

# 3) Google’s search feature automatically suggests correcting spelling mistakes for users when searching queries. This helps users avoid making unintentional errors.

# 4) Bank websites use the dual text field feature to accept sensitive information like passwords or account numbers. The second text field is usually coded to avoid making any errors while providing input values ​​and checking to see if both text field values ​​match.

The need for Poka-Yoke techniques in software development

From countless industry examples, it is now known that the cost of fixing bugs after releasing a product is many times greater than fixing it during the development cycle.

The best solution to avoid problems after release is to introduce Poka-Yoke techniques to help catch bugs in the early stages of software development, which makes fixing them cheaper. . The widespread execution of Poka-Yoke processes depends on the ability of the Tester to capture and eliminate problems.

Examples of Poka-Yoke techniques in software development

  1. Unit testing is one of the most effective means of developing software to prevent errors. Sure, right, because if Dev finds an error in the code and early fix phase, when it comes to Tester, the number of errors will be significantly reduced.
  2. Having the validation of Poka-Yoke techniques in the toolkit is always a good suggestion for developers. Authentication issues should be handled in your code. These authentication issues should also be reviewed and updated periodically.
  3. One of the most effective and popular Poka-Yoke techniques is to hire the right people to prevent errors in your software. This is too ideal, isn’t it


It doesn’t matter what the error is. Humans are not gods, everyone makes mistakes =)) Just don’t make the same mistakes again and again.

I swear I have met this case a lot. Like, when the test finished, it encountered error A, then reported on Dev fix, Dev finished after finishing, the Unit test that Dev reported always is “Oki then, test again”. Then just re-test the error A loomed again appears. Oh, well, it is extremely irritable. Want to rush into fighting always. > “<

And to avoid making the same and repeated errors, there should be a number of processes or checks in place. And Poka-Yoke techniques were developed to solve this problem.

Try it and feel for how effective Poka-Yoke is!

The article was translated from the link:

Share the news now

Source : Viblo