Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-22160

ezpublish/console ezpublish:configure: Could not find 'URLAlias' with identifier '2'

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Blocker Blocker
    • Resolution: Unresolved
    • Affects Version/s: 2013.09
    • Fix Version/s: None
    • Component/s: Upgrading
    • Labels:

      Description

      HI,

      I am trying to upgrade an installation from 4.7 to 5.2 (2013.11) and I am doing this on the command line:

      php ezpublish/console ezpublish:configure --env=prod mysiteaccess myadmin

      I am getting this error:

      [eZ\Publish\Core\Base\Exceptions\NotFoundException]
      Could not find 'URLAlias' with identifier '2'

      Any ideas?

      Best wishes,
      Georg

        Activity

        Hide
        Bertrand Dunogier added a comment -

        It seems that something must be changed in the setup process. I'm not sure where exactly yet, but it's quite likely that the list of languages must be read and used at some point of the upgrade process.

        Show
        Bertrand Dunogier added a comment - It seems that something must be changed in the setup process. I'm not sure where exactly yet, but it's quite likely that the list of languages must be read and used at some point of the upgrade process.
        Hide
        Georg Franz added a comment -

        To solve this issue:

        alter ezpublish/config/ezpublish_setup.yml

        add this:

        languages: [ ger-DE, eng-GB ]

        Best wishes,
        Georg.

        Would be nice to have that somewhere documented...

        Show
        Georg Franz added a comment - To solve this issue: alter ezpublish/config/ezpublish_setup.yml add this: languages: [ ger-DE, eng-GB ] Best wishes, Georg. Would be nice to have that somewhere documented...
        Hide
        Georg Franz added a comment -

        Hi,

        I've found the reason.

        The default language in
        \vendor\ezsystems\ezpublish-kernel\eZ\Publish\Core\Repository\LanguageService.php

        is eng-GB.

        The default language of my site is "ger-DE". If I change the hardcoded value "eng-GB" to "ger-DE" the program works like a charm. (Line 62)

        So, my question:
        How to change the default language without altering the class? Maybe a config setting is missing?

        Best wishes,
        Georg.

        Show
        Georg Franz added a comment - Hi, I've found the reason. The default language in \vendor\ezsystems\ezpublish-kernel\eZ\Publish\Core\Repository\LanguageService.php is eng-GB. The default language of my site is "ger-DE". If I change the hardcoded value "eng-GB" to "ger-DE" the program works like a charm. (Line 62) So, my question: How to change the default language without altering the class? Maybe a config setting is missing? Best wishes, Georg.
        Hide
        Georg Franz added a comment -

        Exception trace:
        () at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/URLAliasService.php:630
        eZ/Publish/Core/Repository/URLAliasService->reverseLookup() at /mypath/vendor/ezsystems/ezpublish-kernel/e
        Z/Publish/Core/SignalSlot/URLAliasService.php:199
        eZ/Publish/Core/SignalSlot/URLAliasService->reverseLookup() at /mypath/vendor/ezsystems/ezpublish-kernel/e
        Z/Publish/Core/MVC/Symfony/Routing/Generator/UrlAliasGenerator.php:176
        eZ/Publish/Core/MVC/Symfony/Routing/Generator/UrlAliasGenerator->getPathPrefixByRootLocationId() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration.php:232
        eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration->getMultiSiteSettings() at /mypath/vendor/ezsys
        tems/ezpublish-kernel/eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration.php:149
        eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration->onBuildKernel() at n/a:n/a
        call_user_func() at /mypath/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/EventDispatcher.p
        hp:164
        Symfony/Component/EventDispatcher/EventDispatcher->doDispatch() at /mypath/vendor/symfony/symfony/src/Symf
        ony/Component/EventDispatcher/EventDispatcher.php:53
        Symfony/Component/EventDispatcher/EventDispatcher->dispatch() at /mypath/vendor/symfony/symfony/src/Symfon
        y/Component/EventDispatcher/ContainerAwareEventDispatcher.php:167
        Symfony/Component/EventDispatcher/ContainerAwareEventDispatcher->dispatch() at /mypath/vendor/ezsystems/ez
        publish-kernel/eZ/Publish/Core/MVC/Legacy/Kernel/Loader.php:155
        eZ/Publish/Core/MVC/Legacy/Kernel/

        {closure}() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core
        /MVC/Legacy/Kernel/Loader.php:72
        eZ/Publish/Core/MVC/Legacy/Kernel/{closure}

        () at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bundle/EzPub
        lishLegacyBundle/SetupWizard/ConfigurationConverter.php:43
        eZ/Bundle/EzPublishLegacyBundle/SetupWizard/ConfigurationConverter->__construct() at /mypath/ezpublish/cac
        he/prod/ezpublishProdProjectContainer.php:2141
        ezpublishProdProjectContainer->getEzpublishLegacy_SetupWizard_ConfigurationConverterService() at /mypath/v
        endor/symfony/symfony/src/Symfony/Component/DependencyInjection/Container.php:319
        Symfony/Component/DependencyInjection/Container->get() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bun
        dle/EzPublishLegacyBundle/Command/LegacyConfigurationCommand.php:50
        eZ/Bundle/EzPublishLegacyBundle/Command/LegacyConfigurationCommand->execute() at /mypath/vendor/symfony/sy
        mfony/src/Symfony/Component/Console/Command/Command.php:244
        Symfony/Component/Console/Command/Command->run() at /mypath/vendor/symfony/symfony/src/Symfony/Component/C
        onsole/Application.php:904
        Symfony/Component/Console/Application->doRunCommand() at /mypath/vendor/symfony/symfony/src/Symfony/Compon
        ent/Console/Application.php:191
        Symfony/Component/Console/Application->doRun() at /mypath/vendor/symfony/symfony/src/Symfony/Bundle/Framew
        orkBundle/Console/Application.php:96
        Symfony/Bundle/FrameworkBundle/Console/Application->doRun() at /mypath/vendor/ezsystems/ezpublish-kernel/e
        Z/Bundle/EzPublishCoreBundle/Console/Application.php:41
        eZ/Bundle/EzPublishCoreBundle/Console/Application->doRun() at /mypath/vendor/symfony/symfony/src/Symfony/C
        omponent/Console/Application.php:121
        Symfony/Component/Console/Application->run() at /mypath/ezpublish/console:27

        Show
        Georg Franz added a comment - Exception trace: () at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core/Repository/URLAliasService.php:630 eZ/Publish/Core/Repository/URLAliasService->reverseLookup() at /mypath/vendor/ezsystems/ezpublish-kernel/e Z/Publish/Core/SignalSlot/URLAliasService.php:199 eZ/Publish/Core/SignalSlot/URLAliasService->reverseLookup() at /mypath/vendor/ezsystems/ezpublish-kernel/e Z/Publish/Core/MVC/Symfony/Routing/Generator/UrlAliasGenerator.php:176 eZ/Publish/Core/MVC/Symfony/Routing/Generator/UrlAliasGenerator->getPathPrefixByRootLocationId() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration.php:232 eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration->getMultiSiteSettings() at /mypath/vendor/ezsys tems/ezpublish-kernel/eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration.php:149 eZ/Bundle/EzPublishLegacyBundle/LegacyMapper/Configuration->onBuildKernel() at n/a:n/a call_user_func() at /mypath/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/EventDispatcher.p hp:164 Symfony/Component/EventDispatcher/EventDispatcher->doDispatch() at /mypath/vendor/symfony/symfony/src/Symf ony/Component/EventDispatcher/EventDispatcher.php:53 Symfony/Component/EventDispatcher/EventDispatcher->dispatch() at /mypath/vendor/symfony/symfony/src/Symfon y/Component/EventDispatcher/ContainerAwareEventDispatcher.php:167 Symfony/Component/EventDispatcher/ContainerAwareEventDispatcher->dispatch() at /mypath/vendor/ezsystems/ez publish-kernel/eZ/Publish/Core/MVC/Legacy/Kernel/Loader.php:155 eZ/Publish/Core/MVC/Legacy/Kernel/ {closure}() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Publish/Core /MVC/Legacy/Kernel/Loader.php:72 eZ/Publish/Core/MVC/Legacy/Kernel/{closure} () at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bundle/EzPub lishLegacyBundle/SetupWizard/ConfigurationConverter.php:43 eZ/Bundle/EzPublishLegacyBundle/SetupWizard/ConfigurationConverter->__construct() at /mypath/ezpublish/cac he/prod/ezpublishProdProjectContainer.php:2141 ezpublishProdProjectContainer->getEzpublishLegacy_SetupWizard_ConfigurationConverterService() at /mypath/v endor/symfony/symfony/src/Symfony/Component/DependencyInjection/Container.php:319 Symfony/Component/DependencyInjection/Container->get() at /mypath/vendor/ezsystems/ezpublish-kernel/eZ/Bun dle/EzPublishLegacyBundle/Command/LegacyConfigurationCommand.php:50 eZ/Bundle/EzPublishLegacyBundle/Command/LegacyConfigurationCommand->execute() at /mypath/vendor/symfony/sy mfony/src/Symfony/Component/Console/Command/Command.php:244 Symfony/Component/Console/Command/Command->run() at /mypath/vendor/symfony/symfony/src/Symfony/Component/C onsole/Application.php:904 Symfony/Component/Console/Application->doRunCommand() at /mypath/vendor/symfony/symfony/src/Symfony/Compon ent/Console/Application.php:191 Symfony/Component/Console/Application->doRun() at /mypath/vendor/symfony/symfony/src/Symfony/Bundle/Framew orkBundle/Console/Application.php:96 Symfony/Bundle/FrameworkBundle/Console/Application->doRun() at /mypath/vendor/ezsystems/ezpublish-kernel/e Z/Bundle/EzPublishCoreBundle/Console/Application.php:41 eZ/Bundle/EzPublishCoreBundle/Console/Application->doRun() at /mypath/vendor/symfony/symfony/src/Symfony/C omponent/Console/Application.php:121 Symfony/Component/Console/Application->run() at /mypath/ezpublish/console:27
        Hide
        Georg Franz added a comment -

        Hi Bertrand,

        thanks for your fast answer!

        I've installed 2013.11 and followed the instructions which are published on your provided url.

        I was not able to call
        php ezpublish/console ezpublish:configure --env=prod mysiteaccess myadmin

        without having a db configuration set in ezpublish_config.yml

        After I've changed the db settings, the script was callable, but threw the exception.

        Best wishes,
        Georg.

        Show
        Georg Franz added a comment - Hi Bertrand, thanks for your fast answer! I've installed 2013.11 and followed the instructions which are published on your provided url. I was not able to call php ezpublish/console ezpublish:configure --env=prod mysiteaccess myadmin without having a db configuration set in ezpublish_config.yml After I've changed the db settings, the script was callable, but threw the exception. Best wishes, Georg.
        Hide
        Bertrand Dunogier added a comment -

        Have you tried a direct upgrade from 4.7 to 5.1 ? We really don't recommend 5.0, since a LOT was fixed in 5.1.

        http://doc.ez.no/eZ-Publish/Upgrading/Direct-upgrading/Direct-upgrading-to-5.1-from-4.7/Direct-upgrading-from-4.7-to-5.1

        Show
        Bertrand Dunogier added a comment - Have you tried a direct upgrade from 4.7 to 5.1 ? We really don't recommend 5.0, since a LOT was fixed in 5.1. http://doc.ez.no/eZ-Publish/Upgrading/Direct-upgrading/Direct-upgrading-to-5.1-from-4.7/Direct-upgrading-from-4.7-to-5.1

          People

          • Assignee:
            Unassigned
            Reporter:
            Georg Franz
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated: