hoaproject / Test

The Hoa\Test library.
https://hoa-project.net/
11 stars 10 forks source link

Can't install with Composer #8

Closed Hywan closed 9 years ago

Hywan commented 10 years ago

My composer.json file:

{
    "require": {
        "hoa/test": "~0.1@dev"
    }
}

And then:

$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - hoa/test 0.x-dev requires atoum/atoum dev-extension -> no matching package found.
    - hoa/test 0.14.09.24 requires atoum/atoum dev-extension -> no matching package found.
    - hoa/test 0.14.09.23 requires atoum/atoum dev-extension -> no matching package found.
    - hoa/test 0.14.09.22 requires atoum/atoum dev-extension -> no matching package found.
    - hoa/test 0.14.09.17 requires atoum/atoum dev-extension -> no matching package found.
    - hoa/test 0.14.09.16 requires atoum/atoum dev-extension -> no matching package found.
    - Installation request for hoa/test ~0.1@dev -> satisfiable by hoa/test[0.14.09.16, 0.14.09.17, 0.14.09.22, 0.14.09.23, 0.14.09.24, 0.x-dev].

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 <https://groups.google.com/d/topic/composer-dev/_g3ASeIFlrc/discussion> for more details.

Read <http://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.

I don't understand :-/.

vonglasow commented 10 years ago

I thinks it's a problem regarding minimum-stability. Atoum have no tag for this branch and for this reason you need to add minimum-stability: dev

Hywan commented 10 years ago

Is #9 help?

jubianchi commented 10 years ago

@Hywan as @vonglasow your have a min-stab problem : hoa/test requires àtoum/atoum@dev-extension` which is a dev package.

Requiring dev packages is rout-only in composer so here, you have two choices:

To me, both are kin of ugly but the second one is perhaps the best one (the less ugly): lowering min-stab could lead to wrong package installation, for example if you have a dep. whit a branch-alias: 0.x-dev and somewhere in another package you require first/lib: 0.*, you'll likely get the dev version.

Using atoum/atoum: *@dev will lower the risk of getting dev packages when not expected : the low min-stab only applies to this single package.

Hywan commented 10 years ago

So, we have to require atoum/atoum: *@dev in all composer.json files or just on hoa/test's one?

jubianchi commented 10 years ago

add atoum/atoum: _@dev *_in all composer.json requiring hoa/test**

;)

Hywan commented 10 years ago

It's stupid. Any workaround? Even a 0.* tag on atoum (we have 0.0.1 but it's old). atoum is going to have a release manager (see https://github.com/atoum/atoum/issues/354) normally, so when we will have tags on atoum, we will have to update all composer.json again (kind of a revert…). Maybe we could wait on atoum to have tags if the issue is resolved quickly?

jubianchi commented 10 years ago

@Hywan it's not stupid, this is how composer works and it's totally good.

Composer refuses to install non-stable package if it is not asked by the root package. This is for code security reason.

When (and if) atoum gets some tags, you'll be able to bypass this behavior but for now, the only "valid" workaround is adding the require-dev everywhere.

Hywan commented 10 years ago

Adding require-dev: hoa/test everywhere is ok, but not dependencies of hoa/test :-/. Do you think the issue https://github.com/atoum/atoum/issues/354 is going to be solved quickly?

jubianchi commented 10 years ago

@Hywan I don't think we can resolve such issue quickly: we have to define the rights/powers of release manager, and don't want atoum to become something driven by a tiny group of human working for a big company like other project have done.

We know this situation will lead to bigger problem...

Hywan commented 10 years ago

@jubianchi Quickly = < 2 months for me. It's ok to not be able to run tests easily on Hoa for the next 2 months if it avoids me to do a long job and revert it few weeks later.

However, if someone is agree to do that job for me, I'm totally in.

jubianchi commented 10 years ago

@Hywan I hope we can fix the RM issue on atoum quickly but, as you may know, I can't (and I don't want) to take this decision only by myself.

I'll try to help you add the deps on Hoa libs this week-end ;)

1e1 commented 10 years ago

up! ;)

Hywan commented 10 years ago

Will up this issue soon.

Hywan commented 9 years ago

Problem solved. Patches coming.

Hywan commented 9 years ago

Closed by #15.