Bug 573070 - Error in AbstractUIPlugin when shutdown "too late"
Summary: Error in AbstractUIPlugin when shutdown "too late"
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.20   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-22 00:46 EDT by Christoph Laeubrich CLA
Modified: 2021-04-22 00:46 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph Laeubrich CLA 2021-04-22 00:46:40 EDT
I have an UI plugin that is started as early as possible (and thus, shut down late), this throws the following exception on shutdown:

org.eclipse.core.runtime.AssertionFailedException: assertion failed: Die Anwendung wurde nicht initialisiert.
	at org.eclipse.core.runtime.Assert.isTrue(Assert.java:113)
	at org.eclipse.core.internal.runtime.InternalPlatform.assertInitialized(InternalPlatform.java:139)
	at org.eclipse.core.internal.runtime.InternalPlatform.getInstanceLocation(InternalPlatform.java:331)
	at org.eclipse.core.runtime.Plugin.savePluginPreferences(Plugin.java:341)
	at org.eclipse.ui.plugin.AbstractUIPlugin.savePreferenceStore(AbstractUIPlugin.java:436)
	at org.eclipse.ui.plugin.AbstractUIPlugin.stop(AbstractUIPlugin.java:539)

The AbstractUIPlugin tries to check for the are to be null or initialized but this check seem to not work anymore due to the exception:

if (instance == null || !instance.isSet())
			// If the instance area is not set there is no point in getting or setting the preferences.
			// There is nothing to save in this case.
			return;