Bug 1007894 - Not much friendly maven error message appears when there is some problem with project (e.g. with dependencies)
Not much friendly maven error message appears when there is some problem with...
Status: CLOSED CURRENTRELEASE
Product: JBoss BRMS Platform 6
Classification: JBoss
Component: Business Central (Show other bugs)
6.0.0
Unspecified Unspecified
medium Severity medium
: ER1
: 6.0.1
Assigned To: Roger Martínez
Radovan Synek
: UserExperience
Depends On:
Blocks: bpms6_ux/brms6_ux
  Show dependency treegraph
 
Reported: 2013-09-13 10:06 EDT by Radovan Synek
Modified: 2015-12-10 05:55 EST (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Summary: A simple error with a Project (for example, missing dependencies) can cause an unfriendly Maven error message being provided to the user, with no details of the actual error. Cause: 1.- Depedency fields were not mandatory 2.- Adding a non existing depedency manually produced a ugly exception to the client. Consequence: Poor feedback to the client. Fix: 1.- Depedency fields are now mandatory 2.- Adding a non existing dependecy produces a friendly error in the user console, no exception is thrown to the client. Result: Improved feedback to the user about the error.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-08-06 15:57:02 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
screen shot (37.97 KB, image/png)
2013-09-17 03:52 EDT, Radovan Synek
no flags Details
fix performed: example of friendly error in the user console (12.35 KB, image/png)
2013-10-16 06:17 EDT, Roger Martínez
no flags Details
second screen shot (64.93 KB, image/png)
2013-12-04 10:47 EST, Radovan Synek
no flags Details

  None (edit)
Description Radovan Synek 2013-09-13 10:06:57 EDT
Description of problem:
Look at the screen shot. This error message provides no help to user without knowledge what is maven, pom.xml and how it works. It says what's wrong in pom.xml - which is some file the user shouldn't have to know it's connected with this screen. And it's very easy to get this error, see the following steps.

steps to reproduce:
1. open any project
2. navigate to Project Screen -> dependencies
3. add dependency (custom one, not from repository)
4. fill in only artifactId
5. save, build & deploy

version:
BRMS-6.0.0.ER2
Comment 1 Edson Tirelli 2013-09-16 16:39:25 EDT
Radovan, I think it is missing the screenshot attachment?
Comment 2 Prakash Aradhya 2013-09-16 22:19:16 EDT
Internal Whiteboard: Beta Blocker → Blocker
Not critical for Beta, but need to address for GA
Comment 3 Radovan Synek 2013-09-17 03:52:08 EDT
Created attachment 798655 [details]
screen shot

Sorry Edson, I forgot to attach it.
Comment 11 Roger Martínez 2013-10-15 14:59:57 EDT
Fixed. Basically two changes are performed:

1.- Depedency fields (groupId artifactId, versionID) are now mandatory.
2.- Adding a non existing dependecy produces a friendly error in the user console, no exception is thrown to the client.

Commits to master
-----------------
- https://github.com/droolsjbpm/kie-wb-common/commit/386ac3f8354b0f406446d8288a103b9d1e71c8c9
- https://github.com/droolsjbpm/drools/commit/4749ccec30e6245b69cff3b1090235b52ef2b01c

Commits to 6.0.x
-----------------
- https://github.com/droolsjbpm/kie-wb-common/commit/978312dfd4f106a252abc6c492d03f3851ce8169

- https://github.com/droolsjbpm/drools/commit/65a561a009db9366f15db34d60bbe2c070d68ac7
Comment 12 Roger Martínez 2013-10-16 06:17:22 EDT
Created attachment 812857 [details]
fix performed: example of friendly error in the user console
Comment 13 Radovan Synek 2013-12-04 10:46:33 EST
I am afraid that what I got by simply following the steps to reproduce from the description of this issue does not look like the user friendly error message in Problems panel, but more like the same error screen as originally reported. A new screen shot attached.
Comment 14 Radovan Synek 2013-12-04 10:47:22 EST
Created attachment 832715 [details]
second screen shot
Comment 15 Pedro Zapata 2013-12-05 11:08:51 EST
No error can be created for any possible unexpected condition. The only way to reduce this is make sure the UI validates most of the possible outcomes, but the latest resort will always print the underlying exception, since it's the only available piece of information.
Comment 16 Roger Martínez 2013-12-09 18:41:35 EST
@Radovan: Agree, it's still happening :S

@Pedro: Agree, the UI was improved and fields cannot be empty. But you can add a GAV into the project pointing to an artifact that does not exist. Then, the UI will pass validations (as the fields are not empty), but when the server side compiles the project then it throws an exception to the client. This exception cannot be more friendly as it's important to show to the user the root cause, but it should not appear as an error popup screen, it should appear in Problems section.
Comment 17 Edson Tirelli 2013-12-12 10:56:43 EST
Further work on this ticket, if any, is postponed to 6.0.1.
Comment 18 Roger Martínez 2014-01-10 17:25:44 EST
Fixed in master branch only, as this issue does not have the bloquer+ flag.

The fix is based on catching maven build exceptions and build an instance of BuildMessages on the fly with the exception details information. Then, the exception is not shown in a popup, it's displayed in problems widget.

Commit in master -> https://github.com/droolsjbpm/guvnor/commit/8fd816e118ba64d0b9f268f34ae69f61895b5df0
Comment 20 Radovan Synek 2014-01-15 03:58:53 EST
Please notice that the doc text provided applies to 6.0.1, as this issue is not fixed for 6.0.0 and therefore it's known issue for 6.0.0, not bug fix. Removing Fix and Result from 6.0.0 release notes should be sufficient.
Comment 22 Radovan Synek 2014-02-21 06:35:47 EST
Verified with BRMS-6.0.1.ER1
Comment 23 Radovan Synek 2014-03-18 10:29:54 EDT
qe_test_coverage:UX problem.

Note You need to log in before you can comment on or make changes to this bug.