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

Error log message: beginTask should only be called once per instance. At least call done() before further invocations on install #335

Open
ajohnson1 opened this issue Sep 26, 2023 · 5 comments
Labels
bug Something isn't working regression Regression defect

Comments

@ajohnson1
Copy link
Contributor

ajohnson1 commented Sep 26, 2023

This was seen on a development version of Eclipse Memory Analyzer built against an Eclipse 4.30-I-build.

eclipse.buildId=unknown
java.fullversion=17.0.6+10
JRE 17 Windows 11 amd64-64-Bit Compressed References 20230117_367 (JIT enabled, AOT enabled)
OpenJ9 - e68fb241f
OMR - f491bbf6f
JCL - 927b34f84c8 based on jdk-17.0.6+10
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_GB
Command-line arguments: -os win32 -ws win32 -arch x86_64

org.eclipse.jface
Warning
Mon Sep 25 18:25:19 BST 2023
beginTask should only be called once per instance. At least call done() before further invocations

java.lang.IllegalStateException: beginTask should only be called once per instance. At least call done() before further invocations
at org.eclipse.jface.operation.AccumulatingProgressMonitor.beginTask(AccumulatingProgressMonitor.java:148)
at org.eclipse.core.runtime.SubMonitor.convert(SubMonitor.java:483)
at org.eclipse.core.runtime.SubMonitor.convert(SubMonitor.java:449)
at org.eclipse.equinox.internal.p2.director.SimplePlanner.getProvisioningPlan(SimplePlanner.java:516)
at org.eclipse.equinox.internal.p2.ui.ProvUI.toCompabilityWithCurrentJREProvisioningPlan(ProvUI.java:329)
at org.eclipse.equinox.internal.p2.ui.dialogs.ProvisioningOperationWizard.lambda$10(ProvisioningOperationWizard.java:346)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
Caused by: java.lang.IllegalStateException: beginTask(, 1000) was called here previously
at org.eclipse.jface.operation.AccumulatingProgressMonitor.beginTask(AccumulatingProgressMonitor.java:155)
at org.eclipse.core.runtime.SubMonitor.convert(SubMonitor.java:483)
at org.eclipse.core.runtime.SubMonitor.convert(SubMonitor.java:449)
at org.eclipse.equinox.internal.p2.operations.PlannerResolutionJob.runModal(PlannerResolutionJob.java:75)
at org.eclipse.equinox.p2.operations.ProfileChangeOperation.resolveModal(ProfileChangeOperation.java:118)
at org.eclipse.equinox.internal.p2.ui.dialogs.ProvisioningOperationWizard.lambda$10(ProvisioningOperationWizard.java:343)
... 1 more

Also reproducible from
https://download.eclipse.org/eclipse/downloads/drops4/I20230924-0600/

  1. Unzip
  2. start Eclipse
  3. help > Install New Software > Work with 2023-12 - https://download.eclipse.org/releases/2023-12
  4. Programming Languages > C/C++ Development Tools
  5. Select
  6. Next
  7. Messaage appears twice in the error log
@vogella
Copy link
Contributor

vogella commented Sep 26, 2023

cc @jukzi @iloveeclipse

@jukzi
Copy link
Contributor

jukzi commented Sep 26, 2023

org.eclipse.equinox.p2.operations.ProfileChangeOperation.resolveModal(IProgressMonitor)
passes monitor to both makeResolveJob() and runModal(). That does not make sense and is forbidden by javadoc. Before passing it to multiple consumers that monitor has to be splitted. I'l create a PR. @ajohnson1 please describe which steps are neseesary to reproduce the issue

@iloveeclipse iloveeclipse added bug Something isn't working regression Regression defect labels Sep 26, 2023
@iloveeclipse
Copy link
Member

Regression from eclipse-platform/eclipse.platform.ui#1115

@jukzi
Copy link
Contributor

jukzi commented Sep 26, 2023

Reproducible with org.eclipse.equinox.p2.tests.ui.dialogs.InstallWizardTest.testInstallWizardResolved()

jukzi pushed a commit to jukzi/p2 that referenced this issue Sep 26, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
jukzi pushed a commit to jukzi/p2 that referenced this issue Sep 28, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
jukzi pushed a commit to jukzi/p2 that referenced this issue Sep 28, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
@vogella
Copy link
Contributor

vogella commented Oct 6, 2023

I also see such an error entry for nightly EGit, see https://bugs.eclipse.org/bugs/show_bug.cgi?id=582511

HannesWell pushed a commit to jukzi/p2 that referenced this issue Oct 8, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Oct 29, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Oct 29, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Oct 29, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Nov 5, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Nov 5, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit to jukzi/p2 that referenced this issue Nov 5, 2023
passing a monitor to two callees requires it to be splitted.

eclipse-equinox#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
HannesWell pushed a commit that referenced this issue Nov 5, 2023
passing a monitor to two callees requires it to be splitted.

#335

Also fixed forgotten monitor.done() in performProvisioningPlan and
improved tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working regression Regression defect
Projects
None yet
Development

No branches or pull requests

4 participants