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

Recursive attempt of WorkbenchPage activation due to runExclusive method continuing running UI event loop #23

Open
pcdavid opened this issue Sep 4, 2022 · 1 comment
Labels
bugzilla Issues migrated from the old Eclipse Bugzilla

Comments

@pcdavid
Copy link
Contributor

pcdavid commented Sep 4, 2022

  • πŸ†” Bugzilla ID: #413912
  • πŸ“˜ Project: Modeling / EMF Services / Transaction
  • πŸ—“ Created: 2013-07-29T10:50:52Z
  • ❓ Status: NEW /
@pcdavid pcdavid added the bugzilla Issues migrated from the old Eclipse Bugzilla label Sep 4, 2022
@pcdavid
Copy link
Contributor Author

pcdavid commented Sep 4, 2022

Comment #0 on Mon Jul 29 2013 12:50:52 GMT+0200 (Central European Summer Time):

Version: Helios Service Release 2
Build id: 20110218-0911

I'm developing GMF based editor. Sometimes I run into a situation when a transaction is run from deeply inside of the WorkbenchPage.setActivePart method. When this happens, org.eclipse.emf.transaction.util.Lock.uiSafeAcquire is called which leads to processing pending UI events to not block UI thread (this is documented in TransactionalEditingDomain.runExclusive method which is usually used to run a transactional read-only operation). But in case when some of the events leads to activation of another WorkbenchPage, its setActivePart throws RuntimeException:

java.lang.RuntimeException: WARNING: Prevented recursive attempt to activate part org.eclipse.ui.views.PropertySheet while still in the middle of activating part <myDiagramPartID>

Most probably WorkbenchPage.setActivePart method does not expect UI loop to continue to be executed inside of it and this leads to such an exception.

I attached two stack traces leading to the exception. One purely consists of Eclipse's inner methods where GraphicalEditPart executes a transaction and in the second trace my property tester executes a transaction to check model for some constraints.

The issue happens rarely, usually when working with huge models, so I cannot provide some exact steps to reproduce it with common editors. Though I've tried to describe the way I understand the problem.

Comment #1 on Sat May 14 2022 15:51:48 GMT+0200 (Central European Summer Time):

Eclipse EMF Transaction is moving away from this bugs.eclipse.org issue tracker to https://github.com/eclipse/emf-transaction.

If this issue is relevant to you and still present in the latest release:

* Create a new issue at https://github.com/eclipse/emf-transaction/issues/.
  * Use as title in GitHub the title of this Bugzilla ticket (may include the bug number or not, at your own convenience)
  * In the GitHub description, start with a link to this bugzilla ticket
  * Optionally add new content to the description if it can helps towards resolution
* Update bugzilla ticket
  * Add to "See also" property (up right column) the link to the newly created GitHub issue
  * Add a comment "Migrated to <link-to-newly-created-GitHub-issue>"
  * Set status as CLOSED MOVED

All issues that remain open will be automatically closed next week or so. Then the Bugzilla component for EMF Transaction will be archived and made read-only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from the old Eclipse Bugzilla
Projects
None yet
Development

No branches or pull requests

1 participant