Я гуглял и читал об этом в течение нескольких дней. Я не могу обновить свой проект Laravel с 5.7 до 5.8 из-за зависимостей. Когда я обновляю значения версии пакета зависимостей в composer.json и пытаюсь выполнить обновление laravel, он игнорирует мои обновления и фактически возвращает их обратно к исходным значениям.
Composer.json
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": "^7.1.3",
"anhskohbo/no-captcha": "^3.0",
"chriskonnertz/open-graph": "^1.0",
"cmgmyr/messenger": "^2.16",
"cviebrock/eloquent-sluggable": "^4.6",
"doctrine/dbal": "^2.8",
"egeloen/http-adapter": "^1.0",
"eilander/gateway": "^5.6",
"exodusanto/administrator": " 5.7.*",
"fideloper/proxy": "^4.0",
"fzaninotto/faker": "^1.8",
"geocoder-php/bing-maps-provider": "^4.0",
"geocoder-php/chain-provider": "^4.0",
"geocoder-php/google-maps-provider": "^4.2",
"geoip2/geoip2": "^2.9",
"hemp/presenter": "^1.0",
"hieu-le/active": "^3.5",
"htmlmin/htmlmin": "^5.8",
"intervention/image": "^2.4",
"laravel/framework": "5.7.*",
"laravel/passport": "^7.0",
"laravel/socialite": "^4.1",
"laravel/tinker": "^1.0",
"laravelcollective/html": "^5.7",
"league/period": "4.1.0",
"maatwebsite/excel": "^3.1",
"morrislaptop/laravel-queue-clear": "^1.1",
"php-http/guzzle6-adapter": "^1.1",
"php-http/message": "^1.7",
"phpoffice/phpspreadsheet": "^1.5",
"pragmarx/firewall": "^2.2",
"predis/predis": "^1.1",
"prettus/l5-repository": "^2.6",
"prettus/laravel-validation": "^1.1",
"ryanwinchester/hubspot-php": "~1.0",
"sammyk/laravel-facebook-sdk": "^3.5",
"santigarcor/laratrust": "^5.0",
"spatie/laravel-newsletter": "^4.2",
"toin0u/geocoder-laravel": "^4.0",
"torann/geoip": "^1.0",
"venturecraft/revisionable": "^1.28",
"watson/sitemap": "^2.0",
"yajra/laravel-datatables-oracle": "^8.9"
},
"require-dev": {
"beyondcode/laravel-dump-server": "^1.0",
"filp/whoops": "^2.0",
"mockery/mockery": "^1.0",
"nunomaduro/collision": "^2.0",
"phpunit/phpunit": "^7.0"
},
"autoload": {
"classmap": [
"database/seeds",
"database/factories"
],
"psr-4": {
"App\\": "app/"
}
},
"autoload-dev": {
"psr-4": {
"Tests\\": "tests/"
}
},
"extra": {
"laravel": {
"dont-discover": [
]
}
},
"scripts": {
"post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"@php artisan key:generate"
],
"post-autoload-dump": [
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"@php artisan package:discover"
]
},
"config": {
"preferred-install": "dist",
"sort-packages": true,
"optimize-autoloader": true
},
"minimum-stability": "dev",
"prefer-stable": true
}
Шаги, которые я предпринимаю:
1) Отредактируйте мой файл composer.json, изменив: "laravel / framework": "5.7. "
на: "laravel / framework ":" 5.8."
2) Запустить обновление композитора
Вывод:
Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update
Package egeloen/http-adapter is abandoned, you should avoid using it. Use php-http/httplug instead.
Generating optimized autoload files
Carbon 1 is deprecated, see how to migrate to Carbon 2.
https://carbon.nesbot.com/docs/#api-carbon-2
You can run ".\vendor\bin\upgrade-carbon" to get help in updating carbon and other frameworks and libraries that depend on it.
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> @php artisan package:discover
Discovered Package: anhskohbo/no-captcha
Discovered Package: beyondcode/laravel-dump-server
Discovered Package: chriskonnertz/open-graph
Discovered Package: cmgmyr/messenger
Discovered Package: cviebrock/eloquent-sluggable
Discovered Package: exodusanto/administrator
Discovered Package: fideloper/proxy
Discovered Package: hemp/presenter
Discovered Package: hieu-le/active
Discovered Package: htmlmin/htmlmin
Discovered Package: intervention/image
Discovered Package: laravel/nexmo-notification-channel
Discovered Package: laravel/passport
Discovered Package: laravel/slack-notification-channel
Discovered Package: laravel/socialite
Discovered Package: laravel/tinker
Discovered Package: laravelcollective/html
Discovered Package: maatwebsite/excel
Discovered Package: morrislaptop/laravel-queue-clear
Discovered Package: nesbot/carbon
Discovered Package: nunomaduro/collision
Discovered Package: pragmarx/firewall
Discovered Package: prettus/l5-repository
Discovered Package: sammyk/laravel-facebook-sdk
Discovered Package: santigarcor/laratrust
Discovered Package: spatie/laravel-newsletter
Discovered Package: toin0u/geocoder-laravel
Discovered Package: torann/geoip
Discovered Package: watson/sitemap
Discovered Package: yajra/laravel-datatables-oracle
Package manifest generated successfully.
Результат:
композитор. Файл json был сброшен для отображения: «laravel / framework»: «5.7. *»
Что я пробовал: 1) Удалите файл composer.lock перед попыткой этого. 2) Выполнение кэша php artisan: очистить до моих обновлений.
Должен быть кто-то, кто сталкивался с этими проблемами, которые могут помочь мне.