Error during creating goals on site: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'description' in 'field list'
Piwik version 3.0.1
Updated Piwik or new install?
I have used old Piwik database, but delete all files and install it from start. So it is similar to new install
Same problem here.
I installed PIWIK 3 new, but used an old PIWIK 2 database for transferring existing data.
Update to PIWIK 3.0.1 didn't help.
Error occurs when I try to create a goal.
try to execute a SQL query like this
ALTER TABLE piwik_goal ADDdescription
varchar(255) NOT NULL DEFAULT ''. I presume the goal plugin was not enabled when you did the update.
@sgiehl @mattab there might be a bug in our updater. I presume when updating core that it also sets all core plugins to that new core version. However, when the plugin was disabled, the update was not actually executed. So either for core plugins we need to manage the updates in "core" updates or we need to fix to record new version only for activated core plugins.
That worked for me! Thanks a lot!
See https://github.com/piwik/piwik/issues/11438 the same also applies not only for core plugin updates but also to the dimension updates
@tsteur might that be fixed meanwhile? Did some local testing and for me the version of deactivated plugins didn't change in db. And when activating the after the update they triggered the included migrations / dimension updates that weren't executed
@sgiehl if you tested it, and updates of a deactivated plugin are executed later, then feel free to close it. Might be good to test with deactivated non-core plugins and deactivated core plugin.
Haven't tried to reproduce it but problem seems to be maybe in https://github.com/matomo-org/matomo/blob/3.13.5-b1/core/Updater.php#L525 where it only returns
loaded plugins and after deactivating
Goals plugin it wasn't appearing there.
Was then executing this query:
update piwik_option set option_value = '3.13.4' where option_name like 'version_%' and option_value = '4.0.0-b1'
and adding an update for goals plugin:
The update did not appear in the updater screen
but the goals plugin remained on the correct version
Then enabled the goals plugin and the component version was increased without actually executing the plugin update.
Actually, I tried it now multiple times and things always worked nicely. No matter if I activate the plugin manually in config file
or whether I activate it through the UI.
The only problem I can see is if the plugin was never marked as installed in the first place then it would maybe falsely record a new version directly https://github.com/matomo-org/matomo/blob/3.13.5-b1/core/Plugin/Manager.php#L1352
This is because the installer assumes that the plugin will install all columns. However, in case of the goals plugin initially core would install the plugin, but goals would only have an update. Basically, we generally either put all install and update logic into a core plugin, or into the core itself but shouldn't mix it.
I think part of this issue be maybe more that we write a test to not have any plugin updates for core plugins but rather define them in