TonyHaikara / silk-platform

0 stars 4 forks source link

Installation procedure: table notification doesn't exist #19

Closed ywarnier closed 3 years ago

ywarnier commented 3 years ago

There's a new issue in the installation process, at step php bin/console doctrine:migrations:migrate :

[notice] Migrating up to DoctrineMigrations\Version20210701135912
[error] Migration DoctrineMigrations\Version20210625154452 failed during Execution. Error: "An exception occurred while executing 'ALTER TABLE notification CHANGE is_read is_read TINYINT(1) DEFAULT '0' NOT NULL':

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'silkc.notification' doesn't exist"

In AbstractMySQLDriver.php line 61:
  An exception occurred while executing 'ALTER TABLE notification CHANGE is_read is_read TINYINT(1) DEFAULT '0' NOT NULL':  
  SQLSTATE[42S02]: Base table or view not found: 1146 Table 'silkc.notification' doesn't exist                              

In Exception.php line 18:
  SQLSTATE[42S02]: Base table or view not found: 1146 Table 'silkc.notification' doesn't exist  

In PDOConnection.php line 132:
  SQLSTATE[42S02]: Base table or view not found: 1146 Table 'silkc.notification' doesn't exist  
ywarnier commented 3 years ago

Importing silk.sql before php bin/console doctrine:migrations:migrate fixes the issue, but then the next step fails:

php bin/console doctrine:fixtures:load --append

  There are no commands defined in the "doctrine:fixtures" namespace.                                                                                                                  

  Did you mean one of these?                                                                                                                                                           
      doctrine                                                                                                                                                                         
      doctrine:cache                                                                                                                                                                   
      doctrine:database                                                                                                                                                                
      doctrine:mapping                                                                                                                                                                 
      doctrine:migrations                                                                                                                                                              
      doctrine:query                                                                                                                                                                   
      doctrine:schema                                                                                                                                                                  

  You may be looking for a command provided by the "DoctrineFixturesBundle" which is currently not installed. Try running "composer require doctrine/doctrine-fixtures-bundle --dev".  

Installing doctrine/doctrine-fixtures-bundle as suggested doesn't fix the issue.

ywarnier commented 3 years ago

Without the fixtures installed but with the yarn commands executed, I get redirected to a /login URL which is "Not Found". It sounds to me like there are some .htaccess missing or instructions to provide in the vhost, or some URL management rows in the database (through fixtures?)

ywarnier commented 3 years ago

The new installation procedure works as documented in README.md, except for the DoctrineFixturesBundle step reported above (which still happens). Working on it...

ywarnier commented 3 years ago

The README has been updated with the --env dev argument and the installation now works fine, thanks to @TonyHaikara