Apache OpenOffice (AOO) Bugzilla – Issue 80296
Reinstallation of an addon does not activate the new version completely.
Last modified: 2013-08-07 15:31:14 UTC
- Install the first version of the attached addon - open a new frame ( writer for example ) - use the addon action => it will show the old and the new value of the configuration entry - deinstall the addon - install the second version of the addon - open a new frame - use the addon action => the first configuration value can be successfuly accessed, the new one is not accessable If the second addon is installed directly both of the values can be successfuly accessed. The restarting of the office did not help. Since it is a general problem for addons it could be a showstopper for 2.3
Created attachment 47269 [details] The first version of the addon.
Created attachment 47270 [details] The second version of the addon.
Created attachment 47271 [details] The netbeans project of the first version of addon.
Created attachment 47272 [details] The netbeans project of the second version of addon.
jsc -> mav: i would not say that it is a showstopper. When you deploy a xcu file with initial defaults as well everything works fine. The problem is that when you don't deploy a xcu file, a new configuration file/data is written under .../user/registry/data/...Office/Custom. Deploying a new an updated schema with the new version doesn't change this old configuration data. The next time the configuration is used on this schema/data it will detect a mismatch between the new schema and the old data. We should analyze it in detail if we can handle this appropriate. In the meanwhile i would document that when a new config schema is defined and deployed, the extension should deploy default data as well.
cc jsc
jl->sb: The configuration should recognize a changed schema and create a new cache if necessary. It could also offer some functionality so that one can externally trigger that the new schema values are used.
Hi, i will provide a second example ... i used oo 2.3 m233 (vista) - install "extensiondialog_1.oxt" i used: unopkg add extensiondialog_1.oxt -v -f --shared - open a calc document, open the calc preferences (Tools -> Options), you will find a new entry "Demo Options Page" - enter some data / change checkbox/radiobutton ... - close with ok, open again, check the entered data/values ... - uninstall "extensiondialog_1.oxt" i used: unopkg remove extensiondialog_1.oxt -v -f --shared - install "extensiondialog_2.oxt", i would suggest to rename it first to "extensiondialog_2.oxt" - enter data in the new textfield "new Field" - close with ok, open again, the data for new field was *not* saved - close openoffice - delete user\registry\cache\org.openoffice.desktop.deployment. options.ExtensionData.dat" - try again, and it will work ... changes made in "extensiondialog_2.oxt" - changed the "ExtensionDialog.xdl" and added a new textfield <dlg:text dlg:id="Label2" dlg:tab-index="9" dlg:left="20" dlg:top="120" dlg:width="50" dlg:height="16" dlg:value="new Field"/> <dlg:textfield dlg:id="String2" dlg:tab-index="10" dlg:left="90" dlg:top="120" dlg:width="90" dlg:height="16"/> - also changed ExtensionDialog.xcs, added: <prop oor:name="String2" oor:type="xs:string"> <value></value> </prop> and last changed the "OptionsEventHandler.java" to allow saving "String2" Oliver
Created attachment 49444 [details] extensiondialog_1
Created attachment 49445 [details] extensiondialog_2
Created attachment 49446 [details] org.openoffice.desktop.deployment.options.ExtensionData.dat
adding me to cc
.
added myself as cc
The problem becomes very penalizing with the "options pages" feature. The xcs file is not updated in case of change. The only simple way to update my options pages is to delete the dat file of my extension before I install it, and it's a bad idea to do that but it works.
As tested on DEV300_m79, with the new configmgr implementation from issue 101955, the scenario from the original description now works, with the following limitation: accessing the second configuration value still fails unless OOo is restarted either after the first AddonsReinstallationBug.oxt version is uninstalled or after the second AddonsReinstallationBug.oxt version is installed. @mav: Please clarify whether the above suits your needs (and this issue can be considered fixed).
Since the restart of the office helps, I would treat the bug as fixed and close it as a duplicate of the issue 101955. It would of course be great if we even would not need to restart, but I am not sure that it is worth the efforts. Anyway, if somebody would like to request the possibility to reinstall an addon without restart, a new issue should be submitted. *** This issue has been marked as a duplicate of 101955 ***