What are the Slack Archives?

Itโ€™s a history of our time together in the Slack Community! Thereโ€™s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.

Because this space is not active, you wonโ€™t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..

Hello everyone, when i try to execute `propel:install` on a fresh installation, i get this following

U016ZPC5480
U016ZPC5480 Posts: 24 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

Hello everyone, when i try to execute propel:install on a fresh installation, i get this following exception. Does anybody know, where it could come from?

// Exception in Thread

Comments

  • U016ZPC5480
    U016ZPC5480 Posts: 24 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet
    php vendor/bin/console propel:install
    <https://yves.onrender.comStore>: DE | Environment: production
    Creating Database
    Adjust propel config for PostgreSQL and missing functions (group_concat)
    Clean schema directory
    Copy and merge schema files
    Build Propel2 classes
    Generate diff for Propel2
    36 tables found in all databases.
    Comparing models...
    Structure of database was modified in datasource "zed": 262 added tables, 36 removed tables
    Error - Exception: Call to a member function getName() on null 
    in /data/vendor/propel/propel/src/Propel/Generator/Platform/DefaultPlatform.php (484)
    
    Command: vendor/bin/console propel:install
    
    Trace: 
    #0 /data/vendor/propel/propel/src/Propel/Generator/Platform/DefaultPlatform.php(604): Propel\Generator\Platform\DefaultPlatform->getColumnListDDL(Array)
    #1 /data/vendor/propel/propel/src/Propel/Generator/Platform/PgsqlPlatform.php(913): Propel\Generator\Platform\DefaultPlatform->getAddIndexDDL(Object(Propel\Generator\Model\Index))
    #2 /data/vendor/propel/propel/src/Propel/Generator/Platform/DefaultPlatform.php(580): Propel\Generator\Platform\PgsqlPlatform->getAddIndexDDL(Object(Propel\Generator\Model\Index))
    #3 /data/vendor/propel/propel/src/Propel/Generator/Platform/DefaultPlatform.php(804): Propel\Generator\Platform\DefaultPlatform->getAddIndicesDDL(Object(Propel\Generator\Model\Table))
    #4 /data/vendor/propel/propel/src/Propel/Generator/Command/MigrationDiffCommand.php(213): Propel\Generator\Platform\DefaultPlatform->getModifyDatabaseDDL(Object(Propel\Generator\Model\Diff\DatabaseDiff))
    #5 /data/vendor/spryker/propel-orm/src/Spryker/Zed/PropelOrm/Communication/Generator/Command/MigrationDiffCommand.php(28): Propel\Generator\Command\MigrationDiffCommand->execute(Object(Symfony\Component\Console\Input\ArrayInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #6 /data/vendor/spryker/propel/src/Spryker/Zed/Propel/Communication/Command/Runner/PropelCommandRunner.php(64): Spryker\Zed\PropelOrm\Communication\Generator\Command\MigrationDiffCommand->run(Object(Symfony\Component\Console\Input\ArrayInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #7 /data/vendor/spryker/propel/src/Spryker/Zed/Propel/Communication/Console/DiffConsole.php(51): Spryker\Zed\Propel\Communication\Command\Runner\PropelCommandRunner->runCommand(Object(Spryker\Zed\PropelOrm\Communication\Generator\Command\MigrationDiffCommand), Object(Symfony\Component\Console\Input\InputDefinition), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #8 /data/vendor/symfony/console/Command/Command.php(255): Spryker\Zed\Propel\Communication\Console\DiffConsole->execute(Object(Symfony\Component\Console\Input\ArrayInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #9 /data/vendor/spryker/kernel/src/Spryker/Zed/Kernel/Communication/Console/Console.php(234): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArrayInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #10 /data/vendor/spryker/propel/src/Spryker/Zed/Propel/Communication/Console/PropelInstallConsole.php(57): Spryker\Zed\Kernel\Communication\Console\Console->runDependingCommand(Object(Spryker\Zed\Propel\Communication\Console\DiffConsole))
    #11 /data/vendor/symfony/console/Command/Command.php(255): Spryker\Zed\Propel\Communication\Console\PropelInstallConsole->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #12 /data/vendor/symfony/console/Application.php(1018): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #13 /data/vendor/symfony/console/Application.php(271): Symfony\Component\Console\Application->doRunCommand(Object(Spryker\Zed\Propel\Communication\Console\PropelInstallConsole), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #14 /data/vendor/spryker/console/src/Spryker/Zed/Console/Communication/Bootstrap/ConsoleBootstrap.php(110): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #15 /data/vendor/symfony/console/Application.php(147): Spryker\Zed\Console\Communication\Bootstrap\ConsoleBootstrap->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
    #16 /data/vendor/spryker/console/bin/console(27): Symfony\Component\Console\Application->run()
    
  • U018XELUZS9
    U018XELUZS9 Posts: 167 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    I would set a breakpoint in the method (e.g. in line 482) and run the command again with -x to see what's inside $columns.

  • Alberto Reyer
    Alberto Reyer Posts: 690 ๐Ÿช - Explorer

    Probably an schema.xml file with no content inside or a table definition without any columns.
    At least that's mostly the reason I got this error

  • U016ZPC5480
    U016ZPC5480 Posts: 24 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    Thanks for your tips! Unfortunately, both have not worked for me. All schemas have at least one column per table and strangely die(); doenโ€™t work on line 482 (with flushed opcache). Iโ€™ll debug further.

  • giovanni.piemontese
    giovanni.piemontese Spryker Solution Partner Posts: 871 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    It can be happen also when a column in schema xml has no definition of type... it happend also for generate entity transfer.. maybe also in this case.. just check it too

  • giovanni.piemontese
    giovanni.piemontese Spryker Solution Partner Posts: 871 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    or an index has no name definition,,, the same for fk etc..

  • U016ZPC5480
    U016ZPC5480 Posts: 24 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    itโ€™s a fresh copy from b2c-demo-shop and as far as i know there are all schem xmls correct.. i am still debugging

  • U018XELUZS9
    U018XELUZS9 Posts: 167 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    and strangelyย die();ย doenโ€™t work on line 482

    This is really strange, are you sure you work on the same file?

  • U016ZPC5480
    U016ZPC5480 Posts: 24 ๐Ÿง‘๐Ÿปโ€๐Ÿš€ - Cadet

    Yes, i am absolutely sure that i work in the correct file. But i think i have found the error: it seems that the PostgreSQL-Database which i have used has some default-tables. When create and use a fresh database it works. However, the error message still irritates me.