Problem/Motivation
Root composer.json requires npm-asset/autonumeric ^4.10.9, found npm-asset/autonumeric[4.10.9] in the lock file but not in remote repositories, make sure you avoid updating this package to keep the one from the lock file.
or
Could not find a matching version of package npm-asset/autonumeric. Check the package spelling, your version constraint and that the package is available in a stability which matches your minimum-stability (stable).
Steps to reproduce
The repository configuration is correct. Since composer search finds it but composer show fails, the issue is almost certainly that Asset Packagist has "forgotten" the package metadata, or your local Composer has cached a "file not found" response.
This happens with Asset Packagist because it is a dynamic bridge—it doesn't keep every NPM package indexed forever. If a package isn't requested for a long time, it can drop out of the active index.
Proposed resolution
Here are the commands to confirm and fix this.
1. The "Smoking Gun" Test
Run this command to see if Asset Packagist actually has the file currently:
curl -I https://asset-packagist.org/p/npm-asset/autonumeric.json
If you get HTTP 404: The package has dropped from their index.
Fix: Go to asset-packagist.org, search for autonumeric in the search bar, and click the result. This forces their server to re-fetch the data from NPM. Once the page loads successfully, run composer update locally.
Or go here: https://asset-packagist.org/package/npm-asset/autonumeric
If you get HTTP 200: The server is fine, and your local cache is the problem.
2. Force Installation (The real test)
composer show can sometimes be unreliable for uninstalled packages in custom repositories. The most direct way to check if it works is to try and require it, which forces a fresh lookup.
composer require npm-asset/autonumeric
If this fails, it will give a much more specific error than "not found" (e.g., "Could not find a version matching...").
3. Clear Cache (If 200 OK but Require Fails)
If the curl was 200 but require still says "not found," your local Composer is stubbornly holding onto a bad cache.
composer clear-cache
composer require npm-asset/autonumericNext Step: Please run the curl command first. If that returns a 404, you must visit the website to re-index it.
It may take a while until it has propagated through all caches and cdns.
Comments
Comment #2
maxilein commentedComment #3
maxilein commentedSometimes this helped: