0

I just recently upgraded Magento from 2.1.10 to 2.2.2. Which brought up quite a few problems with most of the resolved now. Most were fixed by updating Grunt again which I thought I already did right after installing 2.2.2.

But I noticed quite a significant change in the composer.json and composer.lock files. Should I merge my current composer.json with the newer version from 2.2.2? I grabbed the zip folder from github for 2.2.2 to compare and even the "name" is different in this new version. Went from "magento/project-community-edition" to "magento/magento2ce". When updating to a newer release (2.2.3 when it's available) do we now have to use composer require magento/magento2ce 2.2.3?

I searched all the documentation and I do not see anything about these changes in the composer.json. Or if you are supposed to be using the new version. Actually when I updated to 2.2.2, the composer.json.sample was the same as the 2.1.10 version.

Thanks!

** EDIT ** Add Code for both composer.json

composer.json - 2.1.8 with custom modules installed

{
"name": "magento/project-community-edition",
"description": "eCommerce Platform for Growth (Community Edition)",
"type": "project",
"version": "2.1.8",
"license": [
    "OSL-3.0",
    "AFL-3.0"
],
"require": {
    "magento/product-community-edition": "2.2.2",
    "composer/composer": "@alpha",
    "magento/data-migration-tool": "2.2.2",
    "vsourz/html-sitemap": "^1.0",
    "owebia/magento2-module-advanced-shipping-setting": "^2.1",
    "prince/module-faq": "^1.0",
    "faonni/module-re-captcha": "^2.0",
    "shipperhq/module-shipper": "^20.11",
    "shipperhq/module-address-autocomplete": "^20.1",
    "boldcommerce/magento2-ordercomments": "^1.2",
    "mirasvit/module-rma": "^2.0",
    "mirasvit/module-gift-registry": "^1.0",
    "mirasvit/module-core": "^1.2"
},
"require-dev": {
    "phpunit/phpunit": "4.1.0",
    "squizlabs/php_codesniffer": "1.5.3",
    "phpmd/phpmd": "@stable",
    "pdepend/pdepend": "2.4.0",
    "lusitanian/oauth": "~0.3 <=0.7.0",
    "sebastian/phpcpd": "2.0.0",
    "friendsofphp/php-cs-fixer": "~2.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/"
    },
    "mirasvit-gry2": {
        "type": "composer",
        "url": "https://33588:DXNOM7TRBI@packages.mirasvit.com/"
    },
    "mirasvit-rma2": {
        "type": "composer",
        "url": "https://33587:ULWC06IGJH@packages.mirasvit.com/"
    }
},
"extra": {
    "magento-force": "override"
}
}

composer.json - 2.2.2 initial file from download

{
"name": "magento/magento2ce",
"description": "Magento 2 (Open Source)",
"type": "project",
"version": "2.2.2",
"license": [
    "OSL-3.0",
    "AFL-3.0"
],
"require": {
    "php": "7.0.2|7.0.4|~7.0.6|~7.1.0",
    "zendframework/zend-stdlib": "^2.7.7",
    "zendframework/zend-code": "~3.1.0",
    "zendframework/zend-server": "^2.6.1",
    "zendframework/zend-soap": "^2.6.0",
    "zendframework/zend-uri": "^2.5.1",
    "zendframework/zend-validator": "^2.6.0",
    "zendframework/zend-crypt": "^2.6.0",
    "zendframework/zend-console": "^2.6.0",
    "zendframework/zend-modulemanager": "^2.7",
    "zendframework/zend-mvc": "~2.7.12",
    "zendframework/zend-text": "^2.6.0",
    "zendframework/zend-i18n": "^2.7.3",
    "zendframework/zend-eventmanager": "^2.6.3",
    "zendframework/zend-view": "^2.8.1",
    "zendframework/zend-servicemanager": "^2.7.8",
    "zendframework/zend-json": "^2.6.1",
    "zendframework/zend-config": "^2.6.0",
    "zendframework/zend-form": "^2.10.0",
    "zendframework/zend-di": "^2.6.1",
    "zendframework/zend-serializer": "^2.7.2",
    "zendframework/zend-log": "^2.9.1",
    "zendframework/zend-http": "^2.6.0",
    "zendframework/zend-db": "^2.8.2",
    "zendframework/zend-captcha": "^2.7.1",
    "zendframework/zend-session": "^2.7.3",
    "magento/zendframework1": "~1.13.0",
    "colinmollenhour/credis": "1.8.2",
    "colinmollenhour/php-redis-session-abstract": "1.3.4",
    "colinmollenhour/cache-backend-redis": "1.10.2",
    "colinmollenhour/cache-backend-file": "1.4",
    "composer/composer": "1.4.1",
    "monolog/monolog": "^1.17",
    "oyejorge/less.php": "~1.7.0",
    "pelago/emogrifier": "1.2.0",
    "tubalmartin/cssmin": "4.1.0",
    "magento/magento-composer-installer": ">=0.1.11",
    "braintree/braintree_php": "3.25.0",
    "symfony/console": "~2.3, !=2.7.0",
    "symfony/event-dispatcher": "~2.1",
    "symfony/process": "~2.1",
    "phpseclib/phpseclib": "2.0.*",
    "tedivm/jshrink": "~1.2.0",
    "magento/composer": "~1.2.0",
    "lib-libxml": "*",
    "ext-ctype": "*",
    "ext-gd": "*",
    "ext-spl": "*",
    "ext-dom": "*",
    "ext-simplexml": "*",
    "ext-mcrypt": "*",
    "ext-hash": "*",
    "ext-curl": "*",
    "ext-iconv": "*",
    "ext-intl": "*",
    "ext-xsl": "*",
    "ext-mbstring": "*",
    "ext-openssl": "*",
    "ext-zip": "*",
    "ext-pdo_mysql": "*",
    "ext-soap": "*",
    "sjparkinson/static-review": "~4.1",
    "ramsey/uuid": "3.7.1"
},
"require-dev": {
    "phpunit/phpunit": "~6.2.0",
    "squizlabs/php_codesniffer": "3.1.1",
    "phpmd/phpmd": "@stable",
    "pdepend/pdepend": "2.5.0",
    "friendsofphp/php-cs-fixer": "~2.2.0",
    "lusitanian/oauth": "~0.8.10",
    "sebastian/phpcpd": "2.0.4"
},
"replace": {
    "magento/module-marketplace": "100.2.0",
    "magento/module-admin-notification": "100.2.1",
    "magento/module-advanced-pricing-import-export": "100.2.1",
    "magento/module-analytics": "100.2.0",
    "magento/module-authorization": "100.2.0",
    "magento/module-authorizenet": "100.2.0",
    "magento/module-backend": "100.2.2",
    "magento/module-backup": "100.2.1",
    "magento/module-braintree": "100.2.2",
    "magento/module-bundle": "100.2.2",
    "magento/module-bundle-import-export": "100.2.0",
    "magento/module-cache-invalidate": "100.2.0",
    "magento/module-captcha": "100.2.0",
    "magento/module-catalog": "102.0.2",
    "magento/module-catalog-analytics": "100.2.0",
    "magento/module-catalog-import-export": "100.2.2",
    "magento/module-catalog-inventory": "100.2.2",
    "magento/module-catalog-rule": "101.0.2",
    "magento/module-catalog-rule-configurable": "100.2.0",
    "magento/module-catalog-search": "100.2.2",
    "magento/module-catalog-url-rewrite": "100.2.2",
    "magento/module-catalog-widget": "100.2.0",
    "magento/module-checkout": "100.2.2",
    "magento/module-checkout-agreements": "100.2.0",
    "magento/module-cms": "102.0.2",
    "magento/module-cms-url-rewrite": "100.2.0",
    "magento/module-config": "101.0.2",
    "magento/module-configurable-import-export": "100.2.0",
    "magento/module-configurable-product": "100.2.2",
    "magento/module-configurable-product-sales": "100.2.0",
    "magento/module-contact": "100.2.1",
    "magento/module-cookie": "100.2.0",
    "magento/module-cron": "100.2.1",
    "magento/module-currency-symbol": "100.2.0",
    "magento/module-customer": "101.0.2",
    "magento/module-customer-analytics": "100.2.0",
    "magento/module-customer-import-export": "100.2.1",
    "magento/module-deploy": "100.2.2",
    "magento/module-developer": "100.2.1",
    "magento/module-dhl": "100.2.0",
    "magento/module-directory": "100.2.1",
    "magento/module-downloadable": "100.2.1",
    "magento/module-downloadable-import-export": "100.2.0",
    "magento/module-eav": "101.0.1",
    "magento/module-email": "100.2.1",
    "magento/module-encryption-key": "100.2.0",
    "magento/module-fedex": "100.2.0",
    "magento/module-gift-message": "100.2.0",
    "magento/module-google-adwords": "100.2.0",
    "magento/module-google-analytics": "100.2.1",
    "magento/module-google-optimizer": "100.2.1",
    "magento/module-grouped-import-export": "100.2.0",
    "magento/module-grouped-product": "100.2.1",
    "magento/module-import-export": "100.2.2",
    "magento/module-indexer": "100.2.1",
    "magento/module-instant-purchase": "100.2.0",
    "magento/module-integration": "100.2.1",
    "magento/module-layered-navigation": "100.2.0",
    "magento/module-media-storage": "100.2.0",
    "magento/module-msrp": "100.2.0",
    "magento/module-multishipping": "100.2.0",
    "magento/module-new-relic-reporting": "100.2.1",
    "magento/module-newsletter": "100.2.1",
    "magento/module-offline-payments": "100.2.0",
    "magento/module-offline-shipping": "100.2.1",
    "magento/module-page-cache": "100.2.1",
    "magento/module-payment": "100.2.1",
    "magento/module-paypal": "100.2.1",
    "magento/module-persistent": "100.2.0",
    "magento/module-product-alert": "100.2.0",
    "magento/module-product-video": "100.2.1",
    "magento/module-quote": "101.0.2",
    "magento/module-quote-analytics": "100.2.0",
    "magento/module-release-notification": "100.2.0",
    "magento/module-reports": "100.2.2",
    "magento/module-require-js": "100.2.0",
    "magento/module-review": "100.2.2",
    "magento/module-review-analytics": "100.2.0",
    "magento/module-robots": "100.2.0",
    "magento/module-rss": "100.2.0",
    "magento/module-rule": "100.2.0",
    "magento/module-sales": "101.0.2",
    "magento/module-sales-analytics": "100.2.0",
    "magento/module-sales-inventory": "100.2.0",
    "magento/module-sales-rule": "101.0.1",
    "magento/module-sales-sequence": "100.2.0",
    "magento/module-sample-data": "100.2.1",
    "magento/module-search": "100.2.2",
    "magento/module-security": "100.2.0",
    "magento/module-send-friend": "100.2.0",
    "magento/module-shipping": "100.2.2",
    "magento/module-signifyd": "100.2.1",
    "magento/module-sitemap": "100.2.2",
    "magento/module-store": "100.2.2",
    "magento/module-swagger": "100.2.1",
    "magento/module-swatches": "100.2.1",
    "magento/module-swatches-layered-navigation": "100.2.0",
    "magento/module-tax": "100.2.2",
    "magento/module-tax-import-export": "100.2.0",
    "magento/module-theme": "100.2.2",
    "magento/module-translation": "100.2.2",
    "magento/module-ui": "101.0.2",
    "magento/module-ups": "100.2.1",
    "magento/module-url-rewrite": "101.0.2",
    "magento/module-user": "101.0.1",
    "magento/module-usps": "100.2.0",
    "magento/module-variable": "100.2.1",
    "magento/module-vault": "101.0.1",
    "magento/module-version": "100.2.0",
    "magento/module-webapi": "100.2.1",
    "magento/module-webapi-security": "100.2.0",
    "magento/module-weee": "100.2.0",
    "magento/module-widget": "101.0.1",
    "magento/module-wishlist": "101.0.1",
    "magento/module-wishlist-analytics": "100.2.0",
    "magento/theme-adminhtml-backend": "100.2.1",
    "magento/theme-frontend-blank": "100.2.1",
    "magento/theme-frontend-luma": "100.2.2",
    "magento/language-de_de": "100.2.0",
    "magento/language-en_us": "100.2.0",
    "magento/language-es_es": "100.2.0",
    "magento/language-fr_fr": "100.2.0",
    "magento/language-nl_nl": "100.2.0",
    "magento/language-pt_br": "100.2.0",
    "magento/language-zh_hans_cn": "100.2.0",
    "magento/framework": "101.0.2",
    "trentrichardson/jquery-timepicker-addon": "1.4.3",
    "components/jquery": "1.11.0",
    "blueimp/jquery-file-upload": "5.6.14",
    "components/jqueryui": "1.10.4",
    "twbs/bootstrap": "3.1.0",
    "tinymce/tinymce": "3.4.7"
},
"extra": {
    "component_paths": {
        "trentrichardson/jquery-timepicker-addon": "lib/web/jquery/jquery-ui-timepicker-addon.js",
        "components/jquery": [
            "lib/web/jquery.js",
            "lib/web/jquery/jquery.min.js",
            "lib/web/jquery/jquery-migrate.js"
        ],
        "blueimp/jquery-file-upload": "lib/web/jquery/fileUploader",
        "components/jqueryui": [
            "lib/web/jquery/jquery-ui.js"
        ],
        "twbs/bootstrap": [
            "lib/web/jquery/jquery.tabs.js"
        ],
        "tinymce/tinymce": "lib/web/tiny_mce"
    }
},
"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"
    ],
    "exclude-from-classmap": [
        "**/dev/**",
        "**/update/**",
        "**/Test/**"
    ]
},
"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": "stable"
}
  • You only need to change the version of magento/project-community-edition to the version you need. – André Ferraz Jan 26 '18 at 12:41
  • Ok so still update using magento/project-community-edition with the version following. Can you explain the difference between the composer.json and composer.lock files? I'm currently comparing 2.1.8 (which is where I started) to 2.2.2 – RLTcode Jan 26 '18 at 17:06
1

If you use the development tools provided by Magento, you might want to update the dev requirements. The regular requirements are handled by the Magento community meta package, so for production you only need to update the Magento version.

All the additional content like "replace" in the file you posted is only there because it's the Github version of Magento with one single repository. It is only used for core development.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.