php-censor / php-censor

PHP Censor is an open source self-hosted continuous integration server for PHP projects.

Home Page:http://php-censor.info

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Migrations path missing from config file

kromonos opened this issue · comments

After Upgrading from commit 29f9dbd to 3b5a76f I get the error Migrations path missing from config file when I execute migration:
20200703-0351 - Screenshot

I tried to search for some hints, in config.yml what I'm missing, but I couldn't find anything. Any advices?

Hello @kromonos. Thank you for the report.

  1. Now master branch contains feature major release v2.0 (Work in progress). For upgrade to latest stable v1 release use branch release-1.2 (or release-1.1, release-1.0) or tags (Latest release tag 1.2.0). Upgrade to latest master is a bad idea.

  2. Could you run migrate command with flag -vvv for more details?

$ bin/console php-censor-migrations:migrate -vvv

In Config.php line 256:
                                            
  [UnexpectedValueException]                
  Migrations path missing from config file  
                                            

Exception trace:
  at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/robmorgan/phinx/src/Phinx/Config/Config.php:256
 Phinx\Config\Config->getMigrationPaths() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/robmorgan/phinx/src/Phinx/Console/Command/AbstractCommand.php:113
 Phinx\Console\Command\AbstractCommand->bootstrap() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/robmorgan/phinx/src/Phinx/Console/Command/Migrate.php:63
 Phinx\Console\Command\Migrate->execute() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/symfony/console/Command/Command.php:255
 Symfony\Component\Console\Command\Command->run() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/symfony/console/Application.php:1000
 Symfony\Component\Console\Application->doRunCommand() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/symfony/console/Application.php:271
 Symfony\Component\Console\Application->doRun() at /var/customers/webs/kromonos/phpci.kromonos.net/vendor/symfony/console/Application.php:147
 Symfony\Component\Console\Application->run() at /var/customers/webs/kromonos/phpci.kromonos.net/bin/console:11

php-censor-migrations:migrate [-c|--configuration CONFIGURATION] [-p|--parser PARSER] [-e|--environment ENVIRONMENT] [-t|--target TARGET] [-d|--date DATE] [-x|--dry-run] [--fake]

After switching to 1.2 branch, migration works as expected :)

@kromonos 👍 Great! I recommend you to stay on version 1.2 for now.

I will try to fix problem in master but with low priority (Version 2.0 will not have full backward compatibility with version 1.2).

Configuration section b8 was deprecated in version 1.2 and finally removed in master (2.0 WIP). Instead you should use section php-censor for version 2.0. This is the cause of the error.

I added more clear exception for this case to master branch.