Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
As of the release Composer version 1.0.0 on April 5,2016, composer will fail installing dependencies due to Panopoly not using a secure url. You can get around this by explicitly setting secure-http within the composer config to false.
PEAR repository from http://pear.php.net could not be loaded. Your configuration does not allow connections to http://pear.php.net/channel.xml. See https://getcomposer.org/doc/06-config.md#secure-http for details.
Panopoly should default to using https so that stuff works without special configuration in Composer. Patch to come.
Comment | File | Size | Author |
---|---|---|---|
#2 | panopoly-composer_use_https-2718405-2-7.x.patch | 286 bytes | tom friedhof |
Comments
Comment #2
tom friedhof CreditAttribution: tom friedhof at ActiveLAMP commentedHere is the patch.
Comment #3
tom friedhof CreditAttribution: tom friedhof at ActiveLAMP commentedComment #4
eawheeler CreditAttribution: eawheeler commentedThanks for the patch. This and your other patch (https://www.drupal.org/node/2879606) are the only resources I've found addressing some serious Composer Manager installation problems for Panopoly. I'm still getting the following terminal error when enabling Composer.
PEAR repository from https://pear.php.net could not be loaded. Undefined index: channel
More seriously, after enabling I'm shut out of Drupal's configuration UI, i.e. admin/config. I get a white screen with the simple message, "The website encountered an unexpected error. Please try again later." Disabling Composer Manager restores access.
Any insight?
Comment #5
eawheeler CreditAttribution: eawheeler commentedThe WSOD can be avoided by using the dev version of Composer Manager, 7.x-1.x-dev.
7.x-1.8 installs certain composer files to sites/all/modules/composer_manager, not sites/default/files/composer where they belong. Installing to sites/all/modules/composer_manager creates permissions issues since the web server user shouldn't have write permissions to it. It results in the error:
RuntimeException: Error creating directory: public://composer in composer_manager_file_dir() (line 299...
Along with a WSOD at admin/config. Patches have been baked into dev that resolve the permissions issue. However, you still need to apply the patch on this page as well as the one at https://www.drupal.org/node/2879606 before installing Composer Manager dev.
Comment #6
ccjjmartin CreditAttribution: ccjjmartin as a volunteer commentedFor anyone looking at this later, don't try to get this working with composer manager as it is no longer recommended for Drupal 8 after 8.1. For my source of this information see the composer manager project page description: https://www.drupal.org/project/composer_manager
Directly related to this issue, I am also getting the same "Undefined index: channel" error when switching this to https. Maybe this is related to not updating the composer.lock file and only updating the composer.json file?
Setting back to needs work since this appears it isn't working and is probably missing composer.lock updates.
Comment #9
dsnopekThanks for the patch! I've committed it.
With regard to the composer_manager stuff: the current composer.json file in Panopoly is meant to pull in some development dependencies for working on Panopoly. It's NOT setup to make Panopoly into a composer "library" that can be installed via composer. That's absolutely something we should do, but this issue seems to just be about fixing the composer error when using the composer.json file as-is.