Closed goaround closed 6 years ago
As WP Background Processing won't be updated anymore, the package is aliased in the configuration on a fork containing the latest community fixes.
I didn't have an issue when doing a composer install/update, but I'll test this again
I see. I only have the issue when I load WP Rocket via my own composer.json (with wpstarter). I just added https://github.com/tabrisrp/wp-background-processing as a repository there and now it works again.
Great, I'm closing this then
Sorry to resurrect, but I'm relatively new to composer and I'm not sure how to fix this.
$ composer require wp-media/wp-rocket
wp-media/wp-rocket v3.0.4 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
How would I go about adding https://github.com/tabrisrp/wp-background-processing as a repo to my composer.json as mentioned by @goaround
I'd really appreciate a point in the right direction! Thanks!
Just add this as to repositories in your composer.json file
"repositories": [ { "type": "vcs", "url": "https://github.com/tabrisrp/wp-background-processing" } ],
Than composer require wp-media/wp-rocket should work fine
Much appreciated @goaround but I still have the same problem. Using Roots Bedrock my composer.json now looks like:
"repositories": [{
"type": "composer",
"url": "https://wpackagist.org"
},
{
"type": "package",
"package": {
"name": "advanced-custom-fields/advanced-custom-fields-pro",
"version": "5.6.10",
"type": "wordpress-plugin",
"dist": {
"type": "zip",
"url": "https://connect.advancedcustomfields.com/index.php?p=pro&a=download"
},
"require": {
"philippbaschke/acf-pro-installer": "^1.0",
"composer/installers": "^1.0"
}
}
},
{
"type": "vcs",
"url": "https://github.com/tabrisrp/wp-background-processing"
}
],
After doing composer require wp-media/wp-rocket
I still get:
Using version ^3.0 for wp-media/wp-rocket
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- wp-media/wp-rocket v3.0.4 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
- wp-media/wp-rocket v3.0.3 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
- wp-media/wp-rocket v3.0.2 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
- wp-media/wp-rocket v3.0.1 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
- wp-media/wp-rocket v3.0 requires a5hleyrich/wp-background-processing 1.1 as 1.0 -> no matching package found.
- Installation request for wp-media/wp-rocket ^3.0 -> satisfiable by wp-media/wp-rocket[v3.0, v3.0.1, v3.0.2, v3.0.3, v3.0.4].
Potential causes:
- A typo in the package name
- The package is not available in a stable-enough version according to your minimum-stability setting
see <https://getcomposer.org/doc/04-schema.md#minimum-stability> for more details.
- It's a private package and you forgot to add a custom repository to find it
Read <https://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.
Installation failed, reverting ./composer.json to its original content.
Any thoughts?
It may well be that I'm just doing this horribly wrong, so apologies if thats the case!
Scrub that, I'm not exactly sure why, but I got it working after closing my iTerm session and starting a new one. I have a feeling this may have been a bug in iTerm.
Thanks for the help with the extra repo though, much appreciated.
@Tabrisrp, why not make a PR to merge your fork back into the upstream repository? This would prevent us from adding
{
"type": "git",
"url": "https://github.com/tabrisrp/wp-background-processing"
}
into the repository
property of every project that uses WP Rocket. It even makes more sense given the fact that your fork is currently already 8 commits behind the upstream.
I bet @A5hleyRich will happily merge.
Thanks!
@Tabrisrp, I second @tyrann0us's suggestion. We use WP Rocket on dozens of our sites, and we would like to reference the official Packagist repo in our projects, but it's more difficult right now because of the additional overhead of remembering to add this to all of our existing composer files and any new ones in the future. As a second alternative, if you have no intentions of merging back upstream, then create a new composer file for this and add it to Packagist, like most other independently-maintained forks do.
Agreed with @sitdev @tyrann0us . It would be nice to see this resolved properly without needing to add custom repositories to composer.json (especially if not documented in your readme).
+1 for @tyrann0us suggestion.
+1 to @sitdev suggestion... getting the original dependency author of "A5hleyRich/wp-background-processing" to accept a PR may be tricky since it's been dead for over a year.
Surely the simplest solution is to just add your maintained fork to wpackagist.org and require that as the dependency, rather than people having to add an extra custom repo to their composer.json. It's counter-intuitive even if documented, would just be nice to eliminate that extra step!
Why has this not been fixed yet? Offering wp-rocket as a composer package that doesn't install out of the box is kind of silly... Can we either get the maintained fork on wpackagist or list this as wontfix
? This issue isn't "Closed".
Problem 1
Hi,
tried to load wp-rocket 2.11.5 via composer but it seems that a5hleyrich/wp-background-processing 1.1 does not exist? There is only 1.0: https://packagist.org/packages/a5hleyrich/wp-background-processing#1.0