Open natedawg92 opened 7 months ago
Encountering the same problem here as well with a different magento 2 module.
Processing patches configuration
Reading /data/.composer/cache/files/a486481dfeb2830a05510422506d093f/003c7340315e1c5e820d83750fcd7fae9acfc77a.file from cache
- Removing bsscommerce/product-stock-alert (1.3.6)
Executing async command (CWD): rm -rf '/data/.../magento2/vendor/bsscommerce/product-stock-alert'
Reading /data/.composer/cache/files/bsscommerce/product-stock-alert/2e2ff0570ef48a9309c2222a6416a374bfa00c5c.tar from cache
- Loading bsscommerce/product-stock-alert (1.3.6) from cache
- Installing bsscommerce/product-stock-alert (1.3.6): Extracting archive
Executing command (CWD): rm -rf '/data/.../magento2/vendor/bsscommerce/product-stock-alert/view'
Executing command (CWD): rm -rf '/data/.../magento2/vendor/bsscommerce/product-stock-alert/Block'
- Applying patches for bsscommerce/product-stock-alert (1)
~ .../magento2: patches/bsscommerce/product-stock-alert/0001-Fixed-check-for-MSI.patch [NEW]
From 4c63a329c22800126dee5aefffe98fdfa3d32870 Mon Sep 17 00:00:00 2001
From: ...
Date: Thu, 2 Feb 2023 14:37:30 +0100
Subject: [PATCH] Fixed check for MSI
Executing command (/data/.../magento2/vendor/bsscommerce/product-stock-alert): which patch
The provided cwd "/data/.../magento2/vendor/bsscommerce/product-stock-alert" does not exist.
I think this is the same issue as https://github.com/vaimo/composer-patches/issues/111
The workaround is to downgrade to version 5.1.1
composer require vaimo/composer-patches:5.1.1
We notice the same issue with various Mirasvit modules. Had to downgrade as @bogdan-soroka-monsoonconsulting mentioned to be able to continue.
When attempting to patch a package that includes multiple Magento 2 modules (Yes bad package structure) the package will be installed then the subdirectory (containing all the sub modules) will be deleted, the patch then is attempted but obviously fails as there is no file to be patched as it was deleted.
This is happening for me on
mirasvit/module-search-ultimate
Pre-requisites
mirasvit/module-search-ultimate
via composerTo Reproduce Steps to reproduce the behaviour:
composer install
orcomposer patch:apply
Expected
Actual
Notes result from
composer instal -vvv
As can be seen the package to be patched is remove with
rm -rf '/var/www/html/vendor/mirasvit/module-search-ultimate'
, then installed then thesrc
directory is deleted withrm -rf '/var/www/html/vendor/mirasvit/module-search-ultimate/src'
before the patch is applied.I have attempted to install the patch using multiple different cwd options and updating the patch file paths to no avail as well.