Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Composer require fails with "indicates a consistency issue with the repository." even though there isn't #10006

Closed
glaubinix opened this issue Jul 16, 2021 · 0 comments
Labels
Milestone

Comments

@glaubinix
Copy link
Contributor

My composer.json:

{}

Output of composer diagnose:

Checking composer.json: WARNING
No license specified, it is recommended to do so. For closed-source software you may use "proprietary" as license.
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: OK
Checking https connectivity to packagist: OK
Checking github.com oauth access: OK
Checking disk free space: OK
Checking pubkeys:
Tags Public Key Fingerprint: 57815BA2 7E54DC31 7ECC7CC5 573090D0  87719BA6 8F3BB723 4E5D42D0 84A14642
Dev Public Key Fingerprint: 4AC45767 E5EC2265 2F0C1167 CBBB8A2B  0C708369 153E328C AD90147D AFE50952
OK
Checking composer version: OK
Composer version: 2.1.3
PHP version: 7.4.19
PHP binary path: /usr/local/Cellar/php@7.4/7.4.19_1/bin/php
OpenSSL version: OpenSSL 1.1.1k  25 Mar 2021
cURL version: 7.77.0 libz 1.2.11 ssl (SecureTransport) OpenSSL/1.1.1k
zip: extension present, unzip present

When I run this command:

composer require symfony/ux-live-component

I get the following output:

Reading ./composer.json (/Users/glaubinix/Projects/packagist/composer/glaubinix/composer.json)
Loading config file /Users/glaubinix/.composer/config.json
Loading config file /Users/glaubinix/.composer/auth.json
Loading config file ./composer.json (/Users/glaubinix/Projects/packagist/composer/glaubinix/composer.json)
Checked CA file /usr/local/etc/openssl@1.1/cert.pem: valid
Executing command (/Users/glaubinix/Projects/packagist/composer/glaubinix): git branch -a --no-color --no-abbrev -v
Reading /Users/glaubinix/.composer/composer.json
Loading config file /Users/glaubinix/.composer/config.json
Loading config file /Users/glaubinix/.composer/auth.json
Loading config file /Users/glaubinix/.composer/composer.json (/Users/glaubinix/.composer/composer.json)
Loading config file /Users/glaubinix/.composer/auth.json
Reading /Users/glaubinix/.composer/auth.json
Reading /Users/glaubinix/Projects/packagist/composer/glaubinix/vendor/composer/installed.json
Running 2.1.3 (2021-06-09 16:31:20) with PHP 7.4.19 on Darwin / 19.6.0
Downloading https://repo.packagist.org/packages.json
[200] https://repo.packagist.org/packages.json
Writing /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/packages.json into cache
Reading /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/provider-symfony~ux-live-component.json from cache
Downloading https://repo.packagist.org/p2/symfony/ux-live-component.json if modified
[304] https://repo.packagist.org/p2/symfony/ux-live-component.json
Reading /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/provider-symfony~ux-live-component.json from cache
Reading /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/provider-symfony~ux-live-component.json from cache
Reading /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/provider-symfony~ux-live-component~dev.json from cache
Downloading https://repo.packagist.org/p2/symfony/ux-live-component~dev.json if modified
[304] https://repo.packagist.org/p2/symfony/ux-live-component~dev.json
Reading /Users/glaubinix/Library/Caches/composer/repo/https---repo.packagist.org/provider-symfony~ux-live-component.json from cache
Downloading https://packagist.org/search.json?q=symfony/ux-live-component&type=
[200] https://packagist.org/search.json?q=symfony/ux-live-component&type=


  [InvalidArgumentException]
  Could not find package symfony/ux-live-component. It was however found via repository search, wh
  ich indicates a consistency issue with the repository.


Exception trace:
 () at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/src/Composer/Command/InitCommand.php:893
 Composer\Command\InitCommand->findBestVersionAndNameForPackage() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/src/Composer/Command/InitCommand.php:498
 Composer\Command\InitCommand->determineRequirements() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/src/Composer/Command/RequireCommand.php:189
 Composer\Command\RequireCommand->execute() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/vendor/symfony/console/Command/Command.php:245
 Symfony\Component\Console\Command\Command->run() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/vendor/symfony/console/Application.php:835
 Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/vendor/symfony/console/Application.php:185
 Symfony\Component\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/src/Composer/Console/Application.php:312
 Composer\Console\Application->doRun() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/vendor/symfony/console/Application.php:117
 Symfony\Component\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/src/Composer/Console/Application.php:125
 Composer\Console\Application->run() at phar:///usr/local/Cellar/composer/2.0.13/bin/composer/bin/composer:64
 require() at /usr/local/Cellar/composer/2.0.13/bin/composer:24

require [--dev] [--dry-run] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--fixed] [--no-suggest] [--no-progress] [--no-update] [--no-install] [--no-scripts] [--update-no-dev] [-w|--update-with-dependencies] [-W|--update-with-all-dependencies] [--with-dependencies] [--with-all-dependencies] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--] [<packages>]...

And I expected this to happen:

As I am running PHP7.4 and symfony/ux-live-component is only available as a dev version that requires PHP8 I would either expect Composer to tell me that there is no stable version or no version matching my PHP version available.

So either
Could not find package symfony/ux-live-component in any version matching your PHP version, PHP extensions and Composer version

or
Could not find a matching version of package symfony/ux-live-component. Check the package spelling, your version constraint and that the package is available in a stability which matches your minimum-stability (stable).

@Seldaek Seldaek added the Bug label Jul 21, 2021
@Seldaek Seldaek added this to the 2.1 milestone Jul 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants