| Summary: | [aird editor] handle cases where the browser component can not be created | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | [Modeling] Sirius | Reporter: | Pierre-Charles David <pierre-charles.david> | ||||||
| Component: | Core | Assignee: | Project inbox <sirius.core-inbox> | ||||||
| Status: | CLOSED FIXED | QA Contact: | Florian Barbin <florian.barbin> | ||||||
| Severity: | enhancement | ||||||||
| Priority: | P3 | CC: | florian.barbin, pierre.guilet | ||||||
| Version: | 5.0.0 | Keywords: | triaged | ||||||
| Target Milestone: | 5.1.1 | ||||||||
| Hardware: | All | ||||||||
| OS: | Linux | ||||||||
| See Also: |
https://git.eclipse.org/r/111781 https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=4d2760a6531f8ddf7e103eff9aaa5ef2a14e464e |
||||||||
| Whiteboard: | aird_editor ux | ||||||||
| Attachments: |
|
||||||||
|
Description
Pierre-Charles David
New Gerrit change created: https://git.eclipse.org/r/111781 Scenario to see the problem: - Use a bundle where Browser component cannot be instantiated. - Create a new Ecore modeling project - Open aird editor - the rightmost part showing viewpoint descriptions is very thin. Selecting a viewpoint does not show any description in this part. And the error log shows nothing. Solution is to: 1- log an error in error log. 2- Set an error message in this header block telling the browser could not be initialized and that HTML will not be interpreted. 2- replace the browser component by a standard text widget showing description without HTML tags to have at least some input. Gerrit change https://git.eclipse.org/r/111781 was merged to [master]. Commit: http://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=4d2760a6531f8ddf7e103eff9aaa5ef2a14e464e Fixed by 4d2760a6531f8ddf7e103eff9aaa5ef2a14e464e. Note that the root issue (browser component that can not be instanciated) only occurs under Linux, at least to our knowledge, and then only in some configurations of GTK version (2 vs 3), system browser components available (xulrunner, webkitgtk...) and system property. On my plain Debian 9.2 "stretch", I can reproduce it by forcing -Dorg.eclipse.swt.browser.DefaultType=mozilla without the corresponding system packages installed. Created attachment 272037 [details]
The error message now shown when the browser can not be instanciated
With the patch, in contexts where the browser component can not be instanciated, we now display this popup, in addition to logging the error.
Created attachment 272038 [details]
How the aird editor looks in degraded mode
This shows how the right-most component of the aird editor looks in degraded mode with the patch: instead of a browser component we use a plain text area, showing some error message and the extracted text from the HTML source. It's not perfect, but it doesn't have to be, this will only be visible in rare settings, and the important point is that we don't crash and still provide a usable editor.
Verified. At modeling project creation time, the aird editor may not be opened the first time the exception occurs. The user may need to manually open the aird editor. Available in Sirius 5.1.1. See https://wiki.eclipse.org/Sirius/5.1.1 for details. |