Laravel 8 上的 League/flysystem-aws-s3-v3 其他软件包需要较低版本软件包、较低、版本、flysystem

2023-09-06 16:40:37 作者:午夜↑蓝调

当运行 composer require League/flysystem-aws-s3-v3 我得到:

league/flysystem-aws-s3-v3[2.0.0, ..., 2.x-dev] 需要 League/flysystem ^2.0.0 ->找到了 League/flysystem[2.0.0-alpha.1, ..., 2.x-dev] 但该软件包通过部分更新固定为 1.1.3(锁定文件版本),并且该版本不匹配.确保将其列为更新命令的参数.

在我的 composer.json 中没有提到 league/flysystem,但它确实在我的 composer.lock 中显示为 联赛/飞行系统":^1.1",.看起来我有几个包(如 spatie/laravel-backup)将此作为依赖项.

In my composer.json there is no mention of league/flysystem, but it does appear in my composer.lock as "league/flysystem": "^1.1",. It looks like I have a few packages (like spatie/laravel-backup) that have this as an dependancy.

我该如何进行?我不确定如何更新其他软件包作为依赖项的软件包,并且这些其他软件包也已固定为特定版本.

How do I proceed? I'm not sure how to update a package that other packages have as an dependancy, and that these other packages have also fixed to a specific version.

推荐答案

你已经发现:spatie/laravel-backup 还不兼容 league/flysystem v2(很新,昨天发布了!).

As you've found already: spatie/laravel-backup is not yet compatible with league/flysystem v2 (which is pretty new, it got released... yesterday!).

只需要旧";通过 composer 获得该 AWS 软件包的版本需要 League/flysystem-aws-s3-v3:"^1.0".

毕竟这不是 Laravel 本身的问题.

After all, this is not a problem of Laravel itself.