Data-migration-tool: Magento 2.1.1 setup:di:compile fail

Created on 13 Sep 2016  路  7Comments  路  Source: magento/data-migration-tool

When running setup:di:compile script prematurely ends with no error on screen. A check in error log shows:

PHP Fatal error: Cannot declare class Migration\Step\Version11410to2000Test, because the name is already in use in /home/gaxle/public_html/dev/vendor/magento/data-migration-tool/tests/unit/testsuite/Migration/Step/UrlRewrite/Version11410to2000Test.php on line 109

Found that the namespace in that file was missing the "UrlRewrite" on the end. Changing namespace to:

namespace Migration\Step\UrlRewrite;

fixes issue.

acknowledged bug

Most helpful comment

vim vendor/magento/data-migration-tool/tests/unit/testsuite/Migration/Step/UrlRewrite/Version11410to2000Test.php

Replace:

namespace Migration\Step;

With:

namespace Migration\Step\UrlRewrite;

All 7 comments

Hi @jackiellowery
Thank you for posting the issue. Internal ticket to fix it MAGETWO-58366

i am facing same issue can you help with solution

Facing same issue in 2.1.2

vim vendor/magento/data-migration-tool/tests/unit/testsuite/Migration/Step/UrlRewrite/Version11410to2000Test.php

Replace:

namespace Migration\Step;

With:

namespace Migration\Step\UrlRewrite;

That's exactly what my pull request says to fix it @vbogdanmg

We are facing this same issue in 2.1.7 !!! Why hasn't this been fixed yet... is a simple fix?!?!

I'm still having issue #189 (apparently a duplicate of this) of this on 2.1.7 as well. My system.log shows:

[2017-07-12 21:27:03] main.ERROR: /usr/bin/php7.0 -f /home/ubuntu/magento2/bin/magento setup:di:compile 2>&1
Compilation was started.
%message% 0/7 [>---------------------------]   0% 1 sec 42.0 MiB%message% 0/7 [>---------------------------]   0% 1 sec 42.0 MiBProxies code generation... 0/7 [>---------------------------]   0% 1 sec 42.0 MiB
Proxies code generation... 1/7 [====>-----------------------]  14% 1 sec 44.0 MiB
Repositories code generation... 1/7 [====>-----------------------]  14% 1 sec 44.0 MiBPHP Fatal error:  Class 'PHPUnit_Framework_TestCase' not found in vendor/magento/data-migration-tool/tests/integration/testsuite/Migration/Step/PostProcessing/Model/EavLeftoverDataTest.php on line 12

PHPUnit is a dev dependency, and is therefore not installed on the staging server that I'm trying to set up.

Can you please reopen this or #189?

Was this page helpful?
0 / 5 - 0 ratings