Why composer can not find my brand new package on packagist.org?
Asked Answered
C

3

10

I've just created my first component on packagist.org, this is a forked version of greensock-js.

I put "components/greensock-js": "1.11.*@dev" into the require section of my composer.json file, but the issue is composer can't find this package, saying

no matching package found.

What did I do wrong?

Christachristabel answered 25/3, 2014 at 14:22 Comment(1)
I made a typo in greenshock, correct: greensock. ;)Christachristabel
M
4

It is now working fine:

$ c show components/greenshock-js
name     : components/greenshock-js
descrip. : GSAP: Professional-Grade HTML5 Animation
keywords : JS, HTML5, component, animation, gsap
versions : dev-master, 1.11.x-dev

Most likely you just lacked some patience :) It can take up to 10minutes for changes to propagate to composer. This will hopefully be reduced in the future again as we improve the code.

Myceto answered 25/3, 2014 at 15:4 Comment(0)
M
1

If you are using Composer V1, it's worth noting that V1 packagist metadata is updated much less frequently since May '21, as mentioned here.

Reduced v1 metadata API update rate starting in May 2021

The update rate for new versions will be reduced from every-minute currently to once every 15 minutes. This means new releases will take a few minutes longer to be available for installation with Composer 1.x.

Restricted access to unused packages via the v1 metadata API starting in May 2021

This means new packages and old unused packages will only be visible to Composer 2 until someone installs them, at which point they will become visible to Composer 1 as well (within 24h as this process happens on a nightly basis).

If a newly uploaded package is not found, and you are using composer V1, your options are:

  • take the slower updates into account and wait quite a bit longer
  • upgrade to composer V2. V2 packagist metadata is updated much faster than V1 ever was.
Millenary answered 12/5, 2021 at 15:0 Comment(0)
C
-1

This means new packages and old unused packages will only be visible to Composer 2 until someone installs them, at which point they will become visible to Composer 1 as well (within 24h as this process happens on a nightly basis).

So looks like you need to install the package using Composer 2 and wait for 24 hrs for it to become available to be installed with Composer 1.

Cheesy answered 20/7, 2021 at 8:31 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.