|
@@ -14,6 +14,7 @@ namespace Composer\DependencyResolver;
|
|
|
|
|
|
use Composer\Package\CompletePackageInterface;
|
|
|
use Composer\Repository\RepositorySet;
|
|
|
+use Composer\Repository\LockArrayRepository;
|
|
|
use Composer\Semver\Constraint\Constraint;
|
|
|
|
|
|
/**
|
|
@@ -221,6 +222,14 @@ class Problem
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ $nonLockedPackages = array_filter($packages, function ($p) {
|
|
|
+ return !$p->getRepository() instanceof LockArrayRepository;
|
|
|
+ });
|
|
|
+
|
|
|
+ if (!$nonLockedPackages) {
|
|
|
+ return array("- Root composer.json requires $packageName".self::constraintToText($constraint) . ', ', 'found '.self::getPackageList($packages).' in lock file but not in remote repositories, make sure you avoid updating this package to keep the one from lock file.');
|
|
|
+ }
|
|
|
+
|
|
|
return array("- Root composer.json requires $packageName".self::constraintToText($constraint) . ', ', 'found '.self::getPackageList($packages).' but '.(self::hasMultipleNames($packages) ? 'these conflict' : 'it conflicts').' with another require.');
|
|
|
}
|
|
|
|