-
Notifications
You must be signed in to change notification settings - Fork 295
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prefix dependencies to circumvent plugin conflicts #612
Comments
@aaemnnosttv could you help formulate the ACs for this issue, since Felix is mostly out this week? |
Sure thing @marrrmarrr! I'll put something together today. |
CR ✅ |
QA
A few inconsistencies with the AC:
I think these are all OK and likely the AC just wasn't updated when these decisions were made, but flagging here as "strict violations" of the AC as it is now. ThoughtsHow about using |
@aaemnnosttv Correct, these two AC inconsistencies are okay because they make more sense to be as was decided in the meantime. The |
QA ✅See #612 (comment) for details Moving to Approval |
We need to also prefix the generated |
verified |
Any way to make this work with composer due to requiring guzzle 5.3.3 for those setups that have deps that require 6+? /~https://github.com/google/site-kit-wp/blob/1.0.0/composer.json#L18 |
@archon810 all dependencies are now prefixed with a Site Kit specific namespace, so there should be nothing preventing you from using a different version of any dependency 😄 |
Bug Description
We need to prefix Composer dependencies that we deploy as part of the bundled plugin in order to prevent conflicts with other plugins shipping the same dependencies (potentially in different versions).
This would fix issues #223, #246, #610, and possibly others too.
It is terrible that we need to do this, but since WordPress does not provide any dependency mechanism, this is the only way to work within these constraints.
There are several options out there to accomplish that, and we need to decide on one of these (e.g. /~https://github.com/coenjacobs/mozart, /~https://github.com/humbug/php-scoper). Also see ampproject/amp-wp#1867 for the same discussion on the AMP plugin (for which the implications are not as bad because their dependencies are probably less commonly used than the Google API ones).
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
vendor
, but in a prefixed version from athird-party
directory.Google\SiteKitDeps\
.Google\Site_Kit
andGoogle\SiteKitDeps
). See /~https://github.com/wprig/wprig/blob/v2.0/functions.php#L36 for inspiration.release-zip
task must no longer include anything from thevendor
directory in the release. Instead it must include thethird-party
directory.Implementation Brief
Changelog entry
The text was updated successfully, but these errors were encountered: