Composer error when trying to include multi level public personal repositories

I'm splitting up some of my personal code to modularize and reuse it on different projects. I've started using composer recently and have been using it for referencing these modules on my projects.

The following has worked for me so far:

First project composer.json

{
    "name": "mpf/apimodule",
    "version":"dev-main",
    "autoload": {
        "psr-4": {
            "APIModule\\":"classes/"
        }
    }
}
Second project composer.json

{
    "name": "mpf/crawler",
    "version":"dev-main",
    "autoload": {
        "psr-4": {
            "API\\": "classes/"
        }
    },
    "repositories": [
        {
            "type": "vcs",
            "url": "git@github.com:{User}/{Repo}.git"
        }
    ],
    "require": {
        "fabpot/goutte": "^3.2",
        "mpf/apimodule": "dev-main"
    }
}

Both composers are compiled and the project works as intended.

But when I try to add a third layer

Third project composer.json

{
    "autoload": {
        "psr-4": {
            "API\\": "classes/"
        }
    },
    "repositories": [
        {
            "type": "vcs",
            "url": "git@github.com:{User}/{Repo}.git"
        }
    ],
    "require": {
        "mpf/crawler": "dev-main"
    }
}

I get the following error when running the composer update command

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires mpf/crawler dev-main -> satisfiable by mpf/crawler[dev-main].
    - mpf/crawler dev-main requires mpf/apimodule dev-main -> could not be found in any 
version, there may be a typo in the package name.

I've found a similar issue, but my repositories are all public and that was the problem for them.

I've tried running composer -vvv / composer diagnose, but couldn't find any useful information with the results.



Comments

Popular posts from this blog

Spring Elasticsearch Operations

Network Error and Timeout on Authorize.net JS

Object oriented programming concepts (OOPs)