You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While working on #404, I happened to think that when the activation code for an installable is run, it will run before any updates that are needed are run, because the update code is triggered by the extensions loaded action, but activation will happen after that. It occurred to me that this could potentially cause problems, because the activation code will likely be expecting the database to be
up to date. We have not yet experienced any issues from this that we know of, but it is possible that it could bite us in the future, especially when the installable has been deactivated over the course of several code updates that need database updates to run as well
Of course, it is also possible that this change could cause unforeseen issues itself, so I think it needs more consideration before we make a decision as to the right behavior here.
The text was updated successfully, but these errors were encountered:
I suppose that something similar could be said for uninstall: if the code was updated after deactivation, the latest updates wouldn't have run, meaning that the uninstall routine would potentially be expecting the database to be in a different state. This could lead to problems, although in most cases it wouldn't (for example, deleting an option that doesn't exist does nothing). In the case of DB tables, they should only be dropped if they exist, or else database errors will occur. But we already use DROP TABLE IF EXISTS queries anyway, so there should be no problem there. It is something to keep in mind though.
To ensure that it is added to a list, if the installable object is added
in a code update after the extension is initially released.
We also tweak the installable class to ensure that site IDs are only
added once.
Fixes#715
See #404, #714, #713, #704
While working on #404, I happened to think that when the activation code for an installable is run, it will run before any updates that are needed are run, because the update code is triggered by the extensions loaded action, but activation will happen after that. It occurred to me that this could potentially cause problems, because the activation code will likely be expecting the database to be
up to date. We have not yet experienced any issues from this that we know of, but it is possible that it could bite us in the future, especially when the installable has been deactivated over the course of several code updates that need database updates to run as well
Of course, it is also possible that this change could cause unforeseen issues itself, so I think it needs more consideration before we make a decision as to the right behavior here.
The text was updated successfully, but these errors were encountered: