title: Symfony doesn't take my Length Assert in account
body: <p>I'm writing validations on Symfony for a User Entity which has a password attribute.</p>
  <pre><code>namespace AppBundle\Entity;
  
  ...
  
  class User implements UserInterface {
      
      ...
      
      /**
      * @ORM\Column(type=&quot;string&quot;)
      */
      private $password;
  
      /**
      * @Assert\NotBlank(message=&quot;Veuillez indiquer un mot de passe&quot;)
      * @Assert\Length(
      *   min=8,
      *   max=4096,
      *   minMessage=&quot;Votre mot de passe doit contenir au moins {{limit}} cacactères&quot;,
      *   maxMessage=&quot;Votre mot de passe ne doit pas contenir plus de {{limit}} caractères&quot;
      * )
      */
      private $plain_password;
      
      ...
      
  }
  </code></pre>
  <p>As you can see, I prevent the password from being empty and I check that its length is greater or equal to 8 characters.</p>
  <p>But in addition, in the signup form I added a password confirmation thanks to the &quot;Repeated&quot; type provided by Symfony.</p>
  <pre><code>namespace AppBundle\Form;
  
  use Symfony\Component\Form\AbstractType;
  use Symfony\Component\Form\FormBuilderInterface;
  use Symfony\Component\OptionsResolver\OptionsResolver;
  use Symfony\Component\Form\Extension\Core\Type\EmailType;
  use Symfony\Component\Form\Extension\Core\Type\PasswordType;
  use Symfony\Component\Form\Extension\Core\Type\UrlType;
  use Symfony\Component\Form\Extension\Core\Type\RepeatedType;
  use Symfony\Component\Form\Extension\Core\Type\SubmitType;
  
  class UserFormType extends AbstractType {
      public function buildForm(FormBuilderInterface $builder, array $options) {
          $builder
              -&gt;add('email', EmailType::class)
              -&gt;add('plain_password', RepeatedType::class, [
                  'type' =&gt; PasswordType::class,
                  'first_name' =&gt; 'first',
                  'second_name' =&gt; 'confirmation',
                  'invalid_message' =&gt; 'La confirmation ne correspond pas avec le mot de passe'
              ])
              -&gt;add('firstname')
              -&gt;add('lastname')
              -&gt;add('city')
              -&gt;add('website', UrlType::class)
              -&gt;add('facebook')
              -&gt;add('twitter')
              -&gt;add('instagram')
              -&gt;add('avatar')
              -&gt;add('submit', SubmitType::class);
      }
  
      public function configureOptions(OptionsResolver $resolver) {
          $resolver-&gt;setDefaults([
              'data_class' =&gt; 'AppBundle\Entity\User'
          ]);
      }
  }
  </code></pre>
  <p>Now, when I submit the form leaving the password field blank, I get the proper message <em>&quot;Veuillez indiquer un mot de passe&quot;</em>.</p>
  <p>When I submit the form with different values in the two password fields, I get also the proper message <em>&quot;La confirmation ne correspond pas avec le mot de passe&quot;</em>.</p>
  <p>But, when I submit the form with equal and not blank values in the two password fields, but with a length lower than 8; I do not get* any error message and the user is peacefully saved.</p>
  <hr />
  <h3>EDIT:</h3>
  <p>Alsatian: I don't have validation group set for the form</p>
  <p>Controller action:</p>
  <pre><code>public function signupAction(Request $request) {
      $user = new User();
      $form = $this-&gt;createForm(UserFormType::class, $user);
      $form-&gt;handleRequest($request);
  
      if($form-&gt;isSubmitted() &amp;&amp; $form-&gt;isValid()) {
          
          $em = $this-&gt;getDoctrine()-&gt;getManager();
          $em-&gt;persist($user);
          $em-&gt;flush();
          
          return $this-&gt;redirectToRoute('home');
      }
  
      return $this-&gt;render('user/signup.html.twig', [
          'form' =&gt; $form-&gt;createView()
      ]);
  }
  </code></pre>