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

Debug "Prompter" handler dialogs may be hidden behind progress dialog #1373

Closed
iloveeclipse opened this issue May 15, 2024 · 2 comments · Fixed by #1374
Closed

Debug "Prompter" handler dialogs may be hidden behind progress dialog #1373

iloveeclipse opened this issue May 15, 2024 · 2 comments · Fixed by #1374
Assignees
Labels
bug Something isn't working
Milestone

Comments

@iloveeclipse
Copy link
Member

Our users are sometimes killing Eclipse because they claim it is waiting forever with "Progress Information" on starting program execution.

This is a usability issue caused by a bad timing of dialogs. Precondition: launch config must have "launch in background" checkbox disabled like here:

image

Steps leading to the problem

  • Project has compilation errors.
  • User ignores errors and starts debugging execution (because compile error is in unrelated hard to fix code).
  • Launch validation checks take a bit longer, so progress dialog is shown asynchronously by system
  • At same time, right before progress dialog is shown, launch validation shows "compilation error" dialog and waits for user to confirm if we should proceed with the launch.
  • Progress dialog is a bit bigger then the error dialog and is shown over them, so the user can't see error dialog that waits for feedback.
  • User only sees the progress dialog and waits for it to continue, the UI waits for user input...
  • After some time user kills Eclipse

The ProgressMonitorJobsDialog that opens "Progress Information" dialog after 800 ms while waiting on org.eclipse.debug.core.model.LaunchConfigurationDelegate.finalLaunchCheck() opens right after the org.eclipse.debug.internal.ui.launchConfigurations.CompileErrorProjectPromptStatusHandler.handleStatus() opens the "Errors in Workspace" dialog.

I can almost always reproduce the bad timing with breakpoints.

  • Conditional breakpoint in org.eclipse.debug.core.model.LaunchConfigurationDelegate.finalLaunchCheck(ILaunchConfiguration, String, IProgressMonitor) with Thread.sleep(850); "condition" right before errors.add(0, configuration); line.
  • Line breakpoint at the line dialog.open(); in org.eclipse.ui.internal.progress.ProgressManager.scheduleProgressMonitorJob(ProgressMonitorJobsDialog)
  • Line breakpoint at line int open = dialog.open(); in org.eclipse.debug.internal.ui.launchConfigurations.CompileErrorProjectPromptStatusHandler.handleStatus(IStatus, Object)

In that case if I return from debugger to Eclipse debuggee I see only the progress dialog, but not the error one (because it is hidden behind the progress).

Bad state:
image

Bad state "explained":
image

Expected (good) state:
image

I'm thinking about some "forced" shell activation / polling for active status somewhere around org.eclipse.debug.internal.ui.sourcelookup.Prompter.handleStatus(IStatus, Object) code, so that the "shell with the prompt" always forcibly activates itself if hidden by some other shell, but if anyone has a better proposal, you are welcome.

@iloveeclipse iloveeclipse added the bug Something isn't working label May 15, 2024
iloveeclipse added a commit to iloveeclipse/eclipse.platform that referenced this issue May 15, 2024
@jukzi
Copy link
Contributor

jukzi commented May 16, 2024

May be it would be better to just not open the problematic Progress Dialog. Instead it could use the progress bar in the status bar like open-quick-type-hierarchy does.

@iloveeclipse
Copy link
Member Author

May be it would be better to just not open the problematic Progress Dialog. Instead it could use the progress bar in the status bar like open-quick-type-hierarchy does.

I've tried on other occasion but it was quickly dismissed by users as they overlook the tiny progress line and with the possible wait times of some minutes (because of big projects) they want always see the clear progress on the screen.

iloveeclipse added a commit to iloveeclipse/eclipse.platform that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

Fixes eclipse-platform#1373
iloveeclipse added a commit that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

Fixes #1373
@iloveeclipse iloveeclipse self-assigned this May 16, 2024
@iloveeclipse iloveeclipse added this to the 4.32 M3 milestone May 16, 2024
iloveeclipse added a commit to iloveeclipse/eclipse.jdt.debug that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
iloveeclipse added a commit to iloveeclipse/eclipse.pde.ui that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
iloveeclipse added a commit to iloveeclipse/eclipse.jdt.ui that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
iloveeclipse added a commit to eclipse-jdt/eclipse.jdt.debug that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
iloveeclipse added a commit to eclipse-jdt/eclipse.jdt.ui that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
iloveeclipse added a commit to eclipse-pde/eclipse.pde that referenced this issue May 16, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
fedejeanne pushed a commit to fedejeanne/eclipse.pde that referenced this issue Jul 31, 2024
This prevents the dialogs to appear behind the possible opened progress
dialog (or any other modal dialog).

See eclipse-platform/eclipse.platform#1373
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants