簡體   English   中英

無法使用 PHP 7.1.17 在 Magento 2.1.7 上安裝數據遷移工具

[英]Can't install Data Migration Tool on Magento 2.1.7 with PHP 7.1.17

我需要完全使用 php7.1 將數據從 Magento 1.9.2.4 遷移到 2.1.7

我有 Ubuntu 17.10

PHP 7.1.17

我已經在 php7.1.17 上安裝了 Magento 2.1.7,但是我無法安裝數據遷移工具..

我一直在運行這個

composer config repositories.magento composer ttps://repo.magento.com

那么這個

composer require magento/data-migration-tool:2.1.7

    Authentication required (repo.magento.com):
      Username: xxxxxxxxxxxxxxxxxxxxxxxxx
      Password: yyyyyyyyyyyyyyyyyyyyyyyyy
Do you want to store credentials for repo.magento.com in /home/sky/.composer/auth.json ? [Yn] y
./composer.json has been updated                                  
Loading composer repositories with package information
Updating dependencies (including require-dev)                     
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - magento/framework 100.1.7 requires php ~5.6.5|7.0.2|7.0.4|~7.0.6 -> your PHP version (7.1.17) does not satisfy that requirement.
    - magento/framework 100.1.7 requires php ~5.6.5|7.0.2|7.0.4|~7.0.6 -> your PHP version (7.1.17) does not satisfy that requirement.
    - magento/framework 100.1.7 requires php ~5.6.5|7.0.2|7.0.4|~7.0.6 -> your PHP version (7.1.17) does not satisfy that requirement.
    - magento/framework 100.1.7 requires php ~5.6.5|7.0.2|7.0.4|~7.0.6 -> your PHP version (7.1.17) does not satisfy that requirement.
    - Installation request for magento/framework (locked at 100.1.7) -> satisfiable by magento/framework[100.1.7].

但得到那個例外......

誰能幫幫我,lz?

那是我的 composer.json 文件:

{
"name": "magento/project-community-edition",
"description": "eCommerce Platform for Growth (Community Edition)",
"type": "project",
"version": "2.1.7",
"license": [
    "OSL-3.0",
    "AFL-3.0"
],
"require": {
    "magento/product-community-edition": "2.1.7",
    "composer/composer": "@alpha",
    "magento/module-bundle-sample-data": "100.1.*",
    "magento/module-theme-sample-data": "100.1.*",
    "magento/module-catalog-sample-data": "100.1.*",
    "magento/module-tax-sample-data": "100.1.*",
    "magento/phpmodule-customer-sample-data": "100.1.*",
    "magento/module-cms-sample-data": "100.1.*",
    "magento/module-widget-sample-data": "100.1.*",
    "magento/module-catalog-rule-sample-data": "100.1.*",
    "magento/module-sales-rule-sample-data": "100.1.*",
    "magento/module-sales-sample-data": "100.1.*",
    "magento/module-grouped-product-sample-data": "100.1.*",
    "magento/module-downloadable-sample-data": "100.1.*",
    "magento/module-msrp-sample-data": "100.1.*",
    "magento/module-configurable-sample-data": "100.1.*",
    "magento/module-product-links-sample-data": "100.1.*",
    "magento/module-wishlist-sample-data": "100.1.*",
    "magento/module-review-sample-data": "100.1.*",
    "magento/module-swatches-sample-data": "100.1.*",
    "magento/sample-data-media": "100.1.*",
    "magento/module-offline-shipping-sample-data": "100.1.*",
    "magento/data-migration-tool": "2.1.7"
},
"require-dev": {
    "phpunit/phpunit": "4.1.0",
    "squizlabs/php_codesniffer": "1.5.3",
    "phpmd/phpmd": "@stable",
    "pdepend/pdepend": "2.4.0",
    "fabpot/php-cs-fixer": "~1.2",
    "lusitanian/oauth": "~0.3 <=0.7.0",
    "sebastian/phpcpd": "2.0.0"
},
"config": {
    "use-include-path": true
},
"autoload": {
    "psr-4": {
        "Magento\\Framework\\": "lib/internal/Magento/Framework/",
        "Magento\\Setup\\": "setup/src/Magento/Setup/",
        "Magento\\": "app/code/Magento/"
    },
    "psr-0": {
        "": "app/code/"
    },
    "files": [
        "app/etc/NonComposerComponentRegistration.php"
    ]
},
"autoload-dev": {
    "psr-4": {
        "Magento\\Sniffs\\": "dev/tests/static/framework/Magento/Sniffs/",
        "Magento\\Tools\\": "dev/tools/Magento/Tools/",
        "Magento\\Tools\\Sanity\\": "dev/build/publication/sanity/Magento/Tools/Sanity/",
        "Magento\\TestFramework\\Inspection\\": "dev/tests/static/framework/Magento/TestFramework/Inspection/",
        "Magento\\TestFramework\\Utility\\": "dev/tests/static/framework/Magento/TestFramework/Utility/"
    }
},
"minimum-stability": "alpha",
"prefer-stable": true,
"repositories": {
    "0": {
        "type": "composer",
        "url": "https://repo.magento.com/"
    },
    "data-migration-tool": {
        "type": "git",
        "url": "https://github.com/magento/data-migration-tool"
    },
    "magento": {
        "type": "composer",
        "url": "https://repo.magento.com"
    }
},
"extra": {
    "magento-force": "override"
}

}

根據官方文檔,Magento 2.1 與 PHP 7.1 不兼容: https : //devdocs.magento.com/guides/v2.1/install-gde/system-requirements-tech.html

這大概就是問題所在。 考慮遷移到更新版本的 Magento(2.2 確實支持 PHP 7.1)或降級您的 PHP 版本。 我個人會選擇前者。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM