hasen's tech life

Twitter: @hasen

composer installで,"Your requirements could not be resolved to an installable set of packages."というエラーが出たので対応.

# composer installで,"Your requirements could not be resolved to an installable set of packages."というエラーが出たので対応.

# error
$ composer install
> Your requirements could not be resolved to an installable set of packages.
> Problem 1
> - The requested package NAME_SPACE/PACKAGE_NAME could not be found in any version, there may be a typo in the package name.
>
> Potential causes:
> - A typo in the package name
> - The package is not available in a stable-enough version according to your minimum-stability setting
> ... (続く)

# そもそもパッケージ名が間違えていないか,指定しているヴァージョンがあるかをpackagistやGitHubで確認する.
# 今回は以前は存在していたマイナーバージョンが削除されていたために起きていた.
# リリースされているバージョンにcomposer.jsonを書き換えて再実行すると成功.