title: Symfony 4 in new dev project, simple authentification fail with the error "Authentication request could not be processed due to a system problem"
body: <p>From symfony 4, when I try to login, the page return me this error : </p>
  
  <p>"Authentication request could not be processed due to a system problem"</p>
  
  <p>And in my var/log/dev.log, the detailed error is : </p>
  
  <pre><code>[2018-09-02 23:18:23] security.INFO: Authentication request failed. {"exception":"[object] (Symfony\\Component\\Security\\Core\\Exception\\AuthenticationServiceException(code: 0): Class 'App\\Entity\\User' does not exist at /home/www/xxx/yyy/symfoproject/vendor/symfony/security/Core/Authentication/Provider/DaoAuthenticationProvider.php:85, Doctrine\\Common\\Persistence\\Mapping\\MappingException(code: 0): Class 'App/Entity/User' does not exist at /home/www/xxx/yyy/symfoproject/vendor/doctrine/persistence/lib/Doctrine/Common/Persistence/Mapping/MappingException.php:93)"} []
  </code></pre>
  
  <p>I don't understand because the class App/Entity/User exists and I used it for generate my database schema with ./bin/console . </p>
  
  <p>my security.yaml code : (in symfoproject/config/packages/security.yaml)</p>
  
  <pre><code>security:
      # https://symfony.com/doc/current/book/security.html#where-do-users-come-from-user-providers
      encoders:
          App\Entity\User:
              algorithm: bcrypt
      providers:
          my_db_provider:
              entity:
                  class: App\Entity\User
                  property: email
      firewalls:
          #dev:
          #    pattern: ^/(_(profiler|wdt)|css|images|js)/
          #    security: false
          main:
              provider: my_db_provider
              anonymous: ~
              form_login:
                  login_path: home
                  check_path: home
              logout:
                  path: /logout
                  target: /
  
              # activate different ways to authenticate
  
              # http_basic: ~
              # https://symfony.com/doc/current/book/security.html#a-configuring-how-your-users-will-authenticate
  
              # form_login: ~
              # https://symfony.com/doc/current/cookbook/security/form_login_setup.html
      role_hierarchy:
          ROLE_SUPER_ADMIN: [ROLE_USER]
  </code></pre>
  
  <p>My User entity code (in symfoproject/src/Entity/UserEntity.php)</p>
  
  <pre><code>&lt;?php
  
  namespace App\Entity;
  
  use Doctrine\ORM\Mapping as ORM;
  use Symfony\Component\Security\Core\Encoder\BCryptPasswordEncoder;
  use Symfony\Component\Security\Core\User\UserInterface;
  use Symfony\Component\Validator\Constraints as Assert;
  
  /**
   * @ORM\Entity(repositoryClass="App\Repository\UserRepository")
   */
  class User implements \Serializable, UserInterface
  {
      /**
       * @ORM\Id
       * @ORM\GeneratedValue
       * @ORM\Column(type="integer")
       */
      private $id;
  
      /**
       * @ORM\Column(type="string", length=100, unique=true)
       */
      private $email;
  
      /**
       * @ORM\Column(type="string", length=64, nullable=true)
       */
      private $token_activation;
  
      /**
       * @var bool
       * @ORM\Column(name="is_active", type="boolean")
       */
      private $isActive;
  
      /**
       * @ORM\Column(type="string", length=64)
       */
      private $password;
  
      /**
       * @Assert\NotBlank()
       * @Assert\Length(max=4096)
       */
      private $plainPassword;
  
      /**
       * @var array
       * @ORM\Column(name="roles", type="array")
       */
      protected $roles;
  
      /**
       * @var int
       * @ORM\Column(type="smallint", options={"default":0})
       */
      private $initial_roll;
  
      public function __construct(string $email, array $roles = array(), bool $isActive = FALSE, string $password = "coucou", int $initial_roll = 0) {
          $this-&gt;email =$email;
          $brypt = new BCryptPasswordEncoder(4);
          $this-&gt;password = $brypt-&gt;encodePassword($password, $this-&gt;getSalt());
          $this-&gt;roles = $roles;
          $this-&gt;isActive = $isActive;
          $this-&gt;initial_roll = $initial_roll;
      }
  
      public function serialize() {
          return serialize(array(
              $this-&gt;id,
              $this-&gt;email,
              $this-&gt;password,
          ));
      }
  
      public function unserialize($serialized) {
          list (
              $this-&gt;id,
              $this-&gt;email,
              $this-&gt;password,
              ) = unserialize($serialized);
      }
  
      public function getRoles() {
          return $this-&gt;roles;
      }
  
      public function getPassword() {
          return $this-&gt;password;
      }
  
      public function getSalt() {
          return NULL;
      }
  
      public function getUsername() {
          return $this-&gt;email;
      }
  
      public function eraseCredentials() {
          $this-&gt;plainPassword = NULL;
      }
  
      /**
       * @return mixed
       */
      public function getId() {
          return $this-&gt;id;
      }
  
      /**
       * @return mixed
       */
      public function getEmail() {
          return $this-&gt;email;
      }
  
      /**
       * @param mixed $email
       */
      public function setEmail($email): void {
          $this-&gt;email = $email;
      }
  
      /**
       * @return mixed
       */
      public function getTokenActivation() {
          return $this-&gt;token_activation;
      }
  
      /**
       * @param mixed $token_activation
       */
      public function setTokenActivation($token_activation): void {
          $this-&gt;token_activation = $token_activation;
      }
  
      /**
       * @return bool
       */
      public function isActive(): bool {
          return $this-&gt;isActive;
      }
  
      /**
       * @param bool $isActive
       */
      public function setIsActive(bool $isActive): void {
          $this-&gt;isActive = $isActive;
      }
  
      /**
       * @return mixed
       */
      public function getPlainPassword() {
          return $this-&gt;plainPassword;
      }
  
      /**
       * @param mixed $plainPassword
       */
      public function setPlainPassword($plainPassword): void {
          $this-&gt;plainPassword = $plainPassword;
      }
  
      public function toArray() {
          return array(
              "id"=&gt;$this-&gt;getId(),
              "mail"=&gt;$this-&gt;getEmail(),
              "role(s)" =&gt; $this-&gt;getRoles(),
              "actif?" =&gt; $this-&gt;isActive(),
          );
      }
  
      /**
       * @return int
       */
      public function getInitialRoll(): int {
          return $this-&gt;initial_roll;
      }
  
      /**
       * @param int $initial_roll
       */
      public function setInitialRoll(int $initial_roll): void {
          $this-&gt;initial_roll = $initial_roll;
      }
  }
  </code></pre>
  
  <p>I don't understand where is my mystake..someone can help me ? </p>