Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 311270

Summary: [ui] Suggest updates of already installed roots when a conflict occurs
Product: [Eclipse Project] Equinox Reporter: Pascal Rapicault <pascal>
Component: p2Assignee: Pascal Rapicault <pascal>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: dgolovin, fbricon, manderse, mistria, nboldt, pascal.rapicault, snjezana.peco
Version: 3.6   
Target Milestone: Kepler M7   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:
Bug Depends on: 297582    
Bug Blocks:    
Attachments:
Description Flags
First page of the wizard
none
Second page of the wizard (aka remediate page)
none
Third wizard page
none
Another suggested UI for remediation page none

Description Pascal Rapicault CLA 2010-04-30 23:02:05 EDT
For cases where what you are trying to install conflicts with what is already installed, it would be great if the user could be proposed an update of IUs that are in conflicts.
For example I install A and it conflicts with B (for example a singleton blocked by B), then it would be great if p2 could search for a solution where I can install A and maybe update B.
Comment 1 Pascal Rapicault CLA 2013-02-15 00:20:12 EST
This work is sponsored by JBoss.

On Max' suggestion, I analyzed the errors from the Top10 Eclipse Marketplace installations. By far the most frequent installation error is a dependency conflict (For example JBoss Tool can not be installed because m2e 1.1. is installed). The two other type of errors encountered are "missing requirements" and "conflict with content in shared install" (another flavour of a dependency conflict).

To help address the situation with dependency conflicts, I propose to change the workflow such that the user is never shown the dreadful p2 error message. Instead the user would directly be taken to a new remediation page (introduced by this work) where potential solutions on how to proceed with the installation would be shown. 
The content shown on this page would have been computed by p2 which would have taken some liberty with the original user request. To be precise, p2 will have tried to find solutions by combining tweaks to the user request and tweaks to what is already installed.
The user request tweaks would be:
- No change 
- Install any version of the requested software (for example this could lead to the install of something lower than the original request)
- Install as many items as possible (this is necessary when there is a conflict between the elements being installed)ac

The tweaks to what is already installed would be:
- No change
- Allow updates (minimal changes)
- Allow updates and deletions

In order to help understand the workflow changes I have made a mockup.
 - The first wizard page show the user selecting software.
 - The second page is the remediation page which let the user choose the desired tweaks and review the solution.
 - The third page is the installation details which now also shows what is being changed in the install. In this context this page may not be necessary since the user will have been presented choice before.

The acute reader will have noticed that with such high level characterization of the solutions, the proposed solutions may not be meeting the user needs. For example an update to a particular installed software may be proposed, yet the user does not desire to do this update because his/her team mandate the usage of this version. I have looked at a solution where the user could start weighing which installed software he desired more as well as which software he preferred to install over others but the resulting experience would be too complex for most users.

At this point, I believe that the benefits of the proposed solution for the general community vastly outweigh this minor problem.
Comment 2 Pascal Rapicault CLA 2013-02-15 00:22:16 EST
Created attachment 227113 [details]
First page of the wizard
Comment 3 Pascal Rapicault CLA 2013-02-15 00:23:12 EST
Created attachment 227114 [details]
Second page of the wizard (aka remediate page)
Comment 4 Pascal Rapicault CLA 2013-02-15 00:23:37 EST
Created attachment 227115 [details]
Third wizard page
Comment 5 Mickael Istria CLA 2013-02-15 06:44:25 EST
Created attachment 227126 [details]
Another suggested UI for remediation page

This looks promising!
I find interesting to have a view of the error on the remediation case. Although most people won't be interested in it and click "Next", I feel like necessary to see the cause in order to choose the right solution.

See suggested UI.
Comment 6 Pascal Rapicault CLA 2013-02-18 21:21:00 EST
I agree that making the error available is important (for example to report errors), however I don't think it should be as prominent as the screenshot suggests because it will scare people and only so many of them are able to parse the error message to take a decision from it. 
On this page, we want ppl to feel helped.

So in order to make the error available, I suggest to have a button on the remediation page that allow to see the error.


Finally I realize that I forgot to mention in the initial description of the solution that the entries that may not be applicable would be greyed out so the user would not really have to hunt down for a solution.
Comment 7 Susan McCourt CLA 2013-02-25 16:31:03 EST
Pascal asked me on IRC to read this/comment.
I like the general concept for sure.
I found that the permutations on the remediation page were a bit confusing.

In my mind, the main balance point is whether the user cares more about freezing their current installation, and thus modifying the request, or getting exactly what they requested even if it upgrades part of the installation.

So I was suggesting that the least-modifying choices in those two categories be presented.  Something like:

[*] Keep my installation the same and modify request to be compatible
[ ] Upgrade my installation to handle the request

If we could resolve the installation up front so that we knew these were possible, then the user just has to think about that choice.

If we do have to drop into a more advanced mode (remove some stuff, or add stuff) then we could show that instead.  

I guess the basic suggestion is try to resolve the least modifying request up front and present only those options, letting the user pick whether they care more about the exact request or their exact installation.
Comment 8 Pascal Rapicault CLA 2013-04-09 08:18:28 EDT
A initial version of this has been available for the last 2 weeks.