Skip to content
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

required plugins not installed at CLI upgrade? #9881

Closed
filippog opened this issue Mar 6, 2016 · 6 comments
Closed

required plugins not installed at CLI upgrade? #9881

filippog opened this issue Mar 6, 2016 · 6 comments
Labels
answered For when a question was asked and we referred to forum or answered it.
Milestone

Comments

@filippog
Copy link

filippog commented Mar 6, 2016

following up from #9861

The issue was that core:archive was silent because Monolog wasn't loaded. I'm using piwik but with config.ini.php from an earlier version so Monolog wasn't listed there, also I'm using the CLI during the upgrades with console core:update --yes --no-ansi.

My config lists Plugins and PluginsInstalled sections, is there a way to handle situations like this where e.g. Monolog is required?

@quba
Copy link
Contributor

quba commented Mar 7, 2016

I confirm this one. Also had issues with Monolog not installed after upgrade.

@tsteur
Copy link
Member

tsteur commented Mar 7, 2016

'm using piwik but with config.ini.php from an earlier version so Monolog wasn't listed there

I'm not sure what you mean here. If you are using config.ini.php from an earlier version it cannot really work so far. You would basically have to reset the installed Piwik version saved in the database and execute the update again. The problem is that we cannot really know whether plugins are missing on purpose or whether they are missing because an older config file was used.

In general there is an update script for it here: https://github.com/piwik/piwik/blob/2.16.0/core/Updates/2.11.0-b5.php so it should have been activated when updating to Piwik 2.11 or newer.

@quba Have you experienced this with other plugins too? Is Diagnostics plugin enabled?

In general: Please make sure config file is writable for the updater.

@quba
Copy link
Contributor

quba commented Mar 8, 2016

Not sure about the Diagnostics plugin. The bottom-line is that Monolog plugin simply wasn't installed after update (via core:upgrade) from some older Piwik version (I think it was 2.9.1) to 2.15.0. The config file was writable for the updater.

@tsteur
Copy link
Member

tsteur commented Mar 8, 2016

I tried to reproduce it 2 times to update from 2.9.1 to 2.16.0 via CLI and could not reproduce it.

First I updated without making any changes to plugins so it worked anyway since Monolog was activated indirectly via global.ini.php. There was no entry in for Plugins[] in config.ini.php.

So I installed 2.9.1 again, deactivated a plugin so I add a copy of Plugins[] in config.ini.php. I verified Monolog was not there. Then I updated via CLI to 2.16.0 again and Monolog was there.

I think what the issue creator @filippog mentioned is a different use case as an old config.ini.php was used with a newer Piwik version. In this case we cannot really detect such differences. I will close the issue for now but feel free to comment @filippog and I'm happy to reopen the issue again. Ideally, when using an old config file, it is recommended to use it with same old Piwik version and then perform an update again to latest version. If database was already used with a newer Piwik version, this does likely not work. Here it would be so far duty of the user to check if there are eg new plugins and to look over the changelogs. I hope we can improve this one day.

@tsteur tsteur closed this as completed Mar 8, 2016
@tsteur tsteur added the answered For when a question was asked and we referred to forum or answered it. label Mar 8, 2016
@tsteur tsteur added this to the 2.16.1 milestone Mar 8, 2016
@filippog
Copy link
Author

that would explain it @tsteur, thanks! What about PluginsInstalled[] vs Plugins[] in config.ini.php ? Are they supposed to be the same or it is possible to have just one? thanks!

@tsteur
Copy link
Member

tsteur commented Mar 10, 2016

It's possible to have only PluginsInstalled[] after a fresh installation but as soon as you activate or deactivate another plugin it will copy the Plugins[] from global.ini.php to config.ini.php. Usually both are present. Plugins[] defines which are activated, PluginsInstalled[] the ones that are installed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

3 participants