Closed cnovak closed 6 years ago
I originally posted this issue in wrong issue queue, moving it here. @mxr576 made the following comment in response:
Hi, This is not a apigee-client-php issue so it should have been posted rather here: https://github.com/apigee/apigee-edge-drupal.
Have you installed cweagans/composer-patches as a dependency? Have you enabled automatic patching in Drupal's composer.json?
"extra": { "enable-patching": true, "patchLevel": { "drupal/core": "-p2" } }
If you did when you do
composer require drupal/apigee_edge
you should see the following output on the screen.
- Applying patches for php-http/client-common https://patch-diff.githubusercontent.com/raw/php-http/client-common/pull/103.diff (Only add path prefix if the path does not contain it already #103)
So patch is being applied on PHP API Client's dependency.
However, it seems drupal/core patches has not been applied for some reasons for the first run - I'll look into that - so you have to run
composer update none
to ensure those get applied too.
Thanks @mxr576 , I now realize I need to add enable-patching": true
and patchLevel
to get the patches to apply. We should add this to the installation instructions.
Enabling patching is not enough, because Drupal core patches does not get applied in the first time when our module gets installed unless you do not run "composer update --lock" after "composer require drupal/apigee_edge". See https://github.com/cweagans/composer-patches/issues/219
https://github.com/wikimedia/composer-merge-plugin has to be installed and configured properly to make this work.
I created a "composer kickstart" project that has everything configured properly: https://github.com/mxr576/apigee_devportal_composer_kickstart
Closing this issue because of no activity.
Summary
The OAuth Patch for Apigee Edge Client Library for PHP is not getting installed when we run composer.
Steps to Reproduce the behavior
composer update apigee/apigee-client-php
, but the patch was not installed.composer update drupal/apigee_edge
, but the patch was not installed.composer remove drupal/apigee_edge
and thencomposer require drupal/apigee_edge
and the patch was not installed.What are the steps to get the patch installed on a currently running system? If I reinstall a brand new site, will the patch get applied?