Skip to content

Troubleshooter

Geert Derks edited this page Feb 26, 2017 · 4 revisions

In particular situations, some errors might occur.

Application not found

Error message: Fatal error: Class 'Zend\Mvc\Application' not found in \public\index.php on line 14
Occurs on: Pulling from the master branch.
Reason: The environment variable APP_ENV has not been set correctly.
Explanation: The application loads a different configuration file in \index.php depending on whether the application is in a development or in a production environment. The environment variable APP_ENV is used for indicating the environment that the application is run in.
Solution: Uncomment line 19 in \public\.htaccess for setting the environment variable APP_ENV to development.

InvalidFieldNameException, PDOException

Exception: Doctrine\DBAL\Exception\InvalidFieldNameException or Doctrine\DBAL\Driver\PDOException
Error message:

  • An exception occurred while executing '[query]' with params [0]: SQLSTATE[42S22]: Column not found: [number] Uknown column '[column name]' in '[table name]'
  • SQLSTATE[42S22]: Column not found: [number] Unknown column '[column name]' in '[table name]'

Occurs on: Pulling from the master branch.
Reason: The database schema is out of sync with the ORM data model in the source code.
Solution: Update the database schema by running the doctrine schema-tool ./web orm:schema-tool:update --force.
Note: If you get a fatal error Fatal error: Class 'Zend\Mvc\Application' not found in \web on line 16, run export APP_ENV="development" before running the schema-tool.