-
-
Notifications
You must be signed in to change notification settings - Fork 25
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
Prevent vendor conflicts with other WordPress plugins #233
Comments
Very interested in this solution. |
Here's another conflict because of this with the popular WP-Optimize https://wordpress.org/support/topic/update-3-1-1-crashes-my-site/#topic-12931535-replies |
also see https://developer.yoast.com/blog/safely-using-php-dependencies-in-the-wordpress-ecosystem/ it's bit too late to do this in Matomo 4 so might have to do this as part of Matomo 5 |
Generally this is as easy as this by the looks:
(you can configure what files and namespaces etc to replace) The problem is that this won't work actually or only for vendor libraries that only we use internally in the plugin. I wanted to fix https://wordpress.org/support/topic/critical-error-after-upgrade/ to make the plugin work again regarding the newer PHP-DI library but already noticed while reading docs of course it can't work. That's because if if eg renames For when we do Matomo 5 we could prefix some things with Matomo like |
We'll look into this as part of Matomo 5. |
Avoid a conflict with Matomo monolog during report archiving. See: matomo-org/matomo-for-wordpress#233
Hello @tsteur Here's how they proceed in the yoast SEO plugin: https://yoast.com/developer-blog/safely-using-php-dependencies-in-the-wordpress-ecosystem/ |
As far as I saw the proper fix is planned for Matomo 5. Is there some quick fix I can do right now for this issue? Thanks for the awesome work! EDIT for anybody else stumbling onto this: here is the list with incompatible plugins. |
Hello @MichaelSchober It's only plan for Matomo 5.x. Mat |
Any update on this? |
I'm also very interested in this issue. As discussed in #618 this causes the WordPress backend to completly fail. Background:We have a lot of wordpress websites from our customers, where this became a problem in the last couple of days. all of these websites are now "inaccessible" in the backend. The only solution is to completly deactivate the matomo plugin (which is of course very bad, because then no more statistics are collected). Unfortunately, we can't disable the other plugins, as they are indispensable for the functioning of the websites. |
@eigenstil @LordSimal we are currently working on this. You can track the remaining work in the following issues: #840, #841 |
Hey there =) |
@macwinnie the remaining work involves making Matomo for WordPress work with Matomo 5, then just prefixing it and making everything work. I can't give an estimate, but it's the only thing I'm working on right now. |
Has the conflict between Matomo and WP Rocket been resolved with version 5.0? |
@schwarzpunkt WP Rocket fixed the issue on their end. In Matomo for WordPress 5.0 we're also applying the fix so conflicts with other plugins will also go away. However, there appears to be an update issue with 5.0.2 that occurs if you're using a Matomo plugin installed through the marketplace. We're hoping to have that resolved by tomorrow at the latest. |
Matomo for WordPress 5 prefixes some composer dependencies to prevent these types of conflicts, closing this one. |
There is no longer a conflict with Matomo. See: matomo-org/matomo-for-wordpress#233 - Removing awakeningsv/authorizer (1.4.0) - Locking wpackagist-plugin/authorizer (3.6.3.1) - Upgrading wpackagist-plugin/matomo (4.15.3 => 5.0.4)
See https://wordpress.org/support/topic/activation-problem-critical-db-error/#post-12489059 and #19
We have quite a few vendor dependencies meaning there's a chance that other plugins embed the same vendor dependency but an older or more recent version and they aren't compatible with ours.
Doing a quick search found eg google/site-kit-wp#612 which solved this by prefixing vendor libraries see /~https://github.com/google/site-kit-wp/pull/696/files and /~https://github.com/google/site-kit-wp/pull/735/files
To ultimately solve this problem it may be interesting to see if we can do something similar. Might be quite a bit of work that needs to be done directly in core. This will solve a lot of trouble over the years of debugging similar issues.
Can't think of a different way to solve this.
The text was updated successfully, but these errors were encountered: