Problem/Motivation

I am getting below error while installing "drupal/purge"

$ composer require 'drupal/purge:^3.5'
./composer.json has been updated
Running composer update drupal/purge
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

Problem 1
- Root composer.json requires drupal/purge, it could not be found in any version, there may be a typo in the package name.

Potential causes:
- A typo in the package name
- The package is not available in a stable-enough version according to your minimum-stability setting
see for more details.
- It's a private package and you forgot to add a custom repository to find it

Read for further common problems.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

Steps to reproduce

1. Create a directory and add the below composer.json

2. I am using drual-core (10.2.4) on mac (M1 pro)
name : drupal/core
descrip. : Drupal is an open source content management platform powering millions of websites and applications.
keywords :
versions : * 10.2.4
type : drupal-core
license : GNU General Public License v2.0 or later (GPL-2.0-or-later) (OSI approved) https://spdx.org/licenses/GPL-2.0-or-later.html#licenseText
homepage :

3. Composer version
Composer version 2.6.5 2023-10-06 10:11:52

4. Running (composer require 'drupal/purge:^3.5') will give the error

Proposed resolution

The composer should be able to install the "drupal/purge"

Remaining tasks

User interface changes

API changes

Data model changes

Comments

ankithoney created an issue. See original summary.

ankithoney’s picture

Issue summary: View changes
aaron.ferris’s picture

Worked fine here, I wonder if there was an issue at this particular date and time with Packagist?

a****@***** drupal-10.2.3 % composer require 'drupal/purge:^3.5'
./composer.json has been updated
Running composer update drupal/purge
Loading composer repositories with package information
Updating dependencies
Lock file operations: 1 install, 0 updates, 0 removals
  - Locking drupal/purge (3.5.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
  - Installing drupal/purge (3.5.0): Extracting archive
Generating autoload files
45 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
No security vulnerability advisories found.
japerry’s picture

Status: Active » Postponed (maintainer needs more info)

Cannot replicate either. I'll let it sit here for a bit to see if anyone else sees it, but guessing its a fluke...

craigmac’s picture

Just got this error as well:

Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

Problem 1
- Root composer.json requires drupal/date, it could not be found in any version, there may be a typo in the package name.
Problem 2
- Root composer.json requires drupal/rules, it could not be found in any version, there may be a typo in the package name.

Potential causes:
- A typo in the package name
- The package is not available in a stable-enough version according to your minimum-stability setting
see for more details.
- It's a private package and you forgot to add a custom repository to find it

Read for further common problems.

liam morland’s picture

Do you have packages.drupal.org in your composer.json? This needs to be there:

    "repositories": [
        {
            "type": "composer",
            "url": "https://packages.drupal.org/8"
        }
    ],