Domanda

While I tried this: sudo pear install -o pear.doctrine-project.org/DoctrineORM

I got the following error:

    Package "pear.doctrine-project.org/DoctrineORM" dependency  "pear.symfony.com/Console" has no releases
    Package "pear.doctrine-project.org/DoctrineDBAL" dependency "pear.symfony.com/Console" has no releases
    doctrine/DoctrineORM requires package "pear.symfony.com/Console" (version >= 2.0.0)
    doctrine/DoctrineORM requires package "pear.symfony.com/Yaml" (version >= 2.0.0), installed version is 1.0.6
    doctrine/DoctrineDBAL requires package "pear.symfony.com/Console" (version >= 2.0.0)
    No valid packages found
    install failed

Solved the above by doing the following: sudo apt-get purge php-pear

Ended up in results like:

    Removing php-pear ...
    Purging configuration files for php-pear ...
    dpkg: warning: while removing php-pear, directory '/usr/share/doc/php5-common/PEAR' not empty so not removed
    dpkg: warning: while removing php-pear, directory '/usr/share/php/.channels' not empty so not removed

Same was for the following folders:

    /usr/share/php/.registry/
    /usr/share/php/.channels/.alias
    /usr/share/php/data
    /usr/share/doc/php5-common/PEAR/Archive_Tar/docs
    /usr/share/doc/php5-common/PEAR

So I removed them all and then purged php-pear completely and reinstalled it again.

now, sudo pear channel-discover pear.doctrine-project.org also didn't say channel already in registry and the later steps also succeeded.

Though I have solved my problem in the above steps. While I failed using the suggestions stated at comments and answers to this post

But I am just curious what could have been wrong in the first place. How PEAR wasn't being able to fetch proper versions of Doctrine2?

Even the accepted answer's process didn't help.

È stato utile?

Soluzione 2

I have the same problem as this topic states but with Doctrine pear installation.

While I try this: sudo pear install -o pear.doctrine-project.org/DoctrineORM

I get the following error:

        Package "pear.doctrine-project.org/DoctrineORM" dependency  "pear.symfony.com/Console" has no releases
        Package "pear.doctrine-project.org/DoctrineDBAL" dependency "pear.symfony.com/Console" has no releases
        doctrine/DoctrineORM requires package "pear.symfony.com/Console" (version >= 2.0.0)
        doctrine/DoctrineORM requires package "pear.symfony.com/Yaml" (version >= 2.0.0), installed version is 1.0.6
        doctrine/DoctrineDBAL requires package "pear.symfony.com/Console" (version >= 2.0.0)
        No valid packages found
        install failed

I have applied what @Paulo and @Parris suggested in another SO QA. But that did not help. Posting it here just for the record.

Edit:

Solved the above by doing the following: sudo apt-get purge php-pear

Ended up in results like:

        Removing php-pear ...
        Purging configuration files for php-pear ...
        dpkg: warning: while removing php-pear, directory '/usr/share/doc/php5-common/PEAR' not empty so not removed
        dpkg: warning: while removing php-pear, directory '/usr/share/php/.channels' not empty so not removed

Same was for the following folders:

        /usr/share/php/.registry/
        /usr/share/php/.channels/.alias
        /usr/share/php/data
        /usr/share/doc/php5-common/PEAR/Archive_Tar/docs
        /usr/share/doc/php5-common/PEAR

So I removed them all and then purged php-pear completely and reinstalled it again.

now, sudo pear channel-discover pear.doctrine-project.org also didn't say channel already in registry and the later steps also succeeded.

Thanks all!

Altri suggerimenti

You should have upgraded the pear.symfony.com/Yaml package. PEAR listed version 2.0.0 as requirement, but you only had 1.0.6:

$ pear upgrade symfony/yaml

Also, it did not find (compatible) releases of pear.symfony.com/console - this was the main reason for the failure. A solution would have been a pear clear-cache call, followed by a possible pear channel-update pear.symfony.com call. After that, the console dep should be installed automatically.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top