当前位置:   article > 正文

php laravel框架 项目搭建环境运行 composer install 遇到问题_your lock file does not contain a compatible set o

your lock file does not contain a compatible set of packages. please run com

错误代码如下:

  1. Installing dependencies from lock file (including require-dev)
  2. Verifying lock file contents can be installed on current platform.
  3. Your lock file does not contain a compatible set of packages. Please run composer update.
  4. Problem 1
  5. - league/flysystem is locked to version 1.1.10 and an update of this package was not requested.
  6. - league/flysystem 1.1.10 requires ext-fileinfo * -> it is missing from your system. Install or enable PHP's fileinfo extension.
  7. Problem 2
  8. - league/mime-type-detection is locked to version 1.11.0 and an update of this package was not requested.
  9. - league/mime-type-detection 1.11.0 requires ext-fileinfo * -> it is missing from your system. Install or enable PHP's fileinfo extension.
  10. Problem 3
  11. - phpoffice/phpspreadsheet is locked to version 1.26.0 and an update of this package was not requested.
  12. - phpoffice/phpspreadsheet 1.26.0 requires ext-fileinfo * -> it is missing from your system. Install or enable PHP's fileinfo extension.
  13. Problem 4
  14. - league/flysystem 1.1.10 requires ext-fileinfo * -> it is missing from your system. Install or enable PHP's fileinfo extension.
  15. - league/flysystem-aws-s3-v3 1.0.30 requires league/flysystem ^1.0.40 -> satisfiable by league/flysystem[1.1.10].
  16. - league/flysystem-aws-s3-v3 is locked to version 1.0.30 and an update of this package was not requested.
  17. To enable extensions, verify that they are enabled in your .ini files:
  18. - D:\myphp\php.ini
  19. You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
  20. Alternatively, you can run Composer with `--ignore-platform-req=ext-fileinfo` to temporarily ignore these required extensions.

解决方案:

修改安装的 php 目录下,php.ini 解开 extension=fileinfo 的注释,去点前面的分号即可

 修改完后,在执行 composer install 命令,可能有两种情况如下:

  1. 执行成功,可以进行下一步
  2. 还出现错误,错误代码如下:
  1. Installing dependencies from lock file (including require-dev)
  2. Verifying lock file contents can be installed on current platform.
  3. Your lock file does not contain a compatible set of packages. Please run composer update.
  4. Problem 1
  5. - phpoffice/phpspreadsheet is locked to version 1.26.0 and an update of this package was not requested.
  6. - phpoffice/phpspreadsheet 1.26.0 requires ext-gd * -> it is missing from your system. Install or enable PHP's gd extension.
  7. To enable extensions, verify that they are enabled in your .ini files:
  8. - D:\myphp\php.ini
  9. You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
  10. Alternatively, you can run Composer with `--ignore-platform-req=ext-gd` to temporarily ignore these required extensions.

解决方案如下:

执行下面命令:composer install --ignore-platform-req=ext-gd

执行后就成功了!!!

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/繁依Fanyi0/article/detail/780969
推荐阅读
相关标签
  

闽ICP备14008679号