Form validation – Error Message not displaying

Hey,

I’ve been using setErrorByName to set the error messages in custom form. My validation passes and it doesn’t allow the form to submit as it contains some error. But the problem is the error message is not displaying. Can anyone help me please?

Drupal version: 


Source: https://www.drupal.org/taxonomy/term/4/feed