I've been running MediaWiki under PHP 8.1 for a while and for numerous reasons I want to downgrade to 7.4. I've tried switchin the version of PHP and this works, but MediaWiki then throws a dependency error for composer, citing that some require PHP 8.1 or above.
To debug this, I've composer depends php | grep 8.1 and it yields, phpspec/prophecy v1.17.0 requires php (^7.2 || 8.0.* || 8.1.* || 8.2.*), which seems to be the package causing the issue—I think. I can't figure out how to remove this and require a version of this dependency that works with 7.4.
I've tried deleting the vendor folder, and also the composer.lock folder, and then switching to PHP 7.4, and running composer install, composer update, neither of which solve the issue and it is the same dependency which keeps reappearing when grepping.
Anyone any ideas what is happening here? And how I can force a version of phpsec/prophecy?