Composer将依赖项更新为旧版本

时间:2017-08-05 14:05:11

标签: php composer-php

我经常在项目中运行composer update,然后检查更新了哪些依赖项。但今天我发现了一个奇怪的输出:

Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 0 installs, 2 updates, 0 removals
  - Updating phpdocumentor/type-resolver (0.4.0 => 0.3.0): Downloading (100%)
  - Updating phpdocumentor/reflection-docblock (3.2.0 => 3.2.1): Downloading (100%)
Writing lock file

你可以看到phpdocumentor / type-resolver包从0.4.0降级到0.3.0,尽管命令是update。 是正常还是错误或其他什么?

1 个答案:

答案 0 :(得分:0)

我似乎找到了答案。它在此提交中:Downgrade phpdocumentor/type-resolver to 0.3

In order to restore a bc break made in 3.2.0 I downgraded the type-resolver. This makes the version less compatible with php 7.1 But will help our users to upgrade.

确实phpdocumentor / type-resolver是phpdocumentor / reflection-docblock的依赖项,其维护者故意降级类型解析器。所以一切都很正常。而且它不是作曲家的错误。这是我第一次看到这样的行为,这就是为什么我发现它很奇怪。