| Summary: | error recovery after failed to-be-imported project analysis | ||||||
|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Milos Kleint <mkleint> | ||||
| Component: | m2e | Assignee: | Milos Kleint <mkleint> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | major | ||||||
| Priority: | P2 | CC: | igor, pascal | ||||
| Version: | unspecified | ||||||
| Target Milestone: | --- | ||||||
| Hardware: | PC | ||||||
| OS: | Mac OS X - Carbon (unsup.) | ||||||
| Whiteboard: | |||||||
| Bug Depends on: | |||||||
| Bug Blocks: | 339112 | ||||||
| Attachments: |
|
||||||
Generally, I think we should warn but allow import. For this specific error, if the project builds from cli please open separate bugreport with steps to reproduce. the problem shows in our m2e-core sourcebase for example where we have test projects that get scanned along with the "normal" projects. can we skip and note the failed projects and return a partial LifecycleMappingConfiguration instance from the LifecycleMappingConfiguration.calculate() method? The line of thinking is that even if some projects fail to load we want to have the mapping resolved for the rest. M2e codebase does not have aggregator pom.xml in the root, in which case project scanner just looks for all pom.xml files. Import from .parent project works fine. I do not know how much effort we need to put in no-aggregator case, tbh. Despite the particular case where this got encountered (project without aggregator), or things that fail importing (broken pom, what not), we should still handle that gracefully. This has been fixed in 0.13 that is work in progress until mid June when Indigo ship. In the meantime you can try it from http://download.eclipse.org/technology/updates/M or http://download.eclipse.org/technology/updates/N if you want to be on the bleeding edge. Sorry, wrong bug! (In reply to comment #3) > M2e codebase does not have aggregator pom.xml in the root, in which case > project scanner just looks for all pom.xml files. Import from .parent project > works fine. I do not know how much effort we need to put in no-aggregator case, > tbh. can we change that to look for all pom files but just one level deep? either only look in direct subfolders of the root or look deeper but once a folder with pom.xml is found, we no longer traverse the child directories? these attempt to improve the scanning in the case of no-pom root folder http://git.eclipse.org/c/m2e/m2e-core.git/commit/?id=aa4b0e45053781b515df653639bc463829d68b4c https://github.com/sonatype/m2e-core-tests/commit/ea0802c966b0d851614cb182b5eba503894d8ea1 http://git.eclipse.org/c/m2e/m2e-core.git/commit/?id=57b8a9ffcd0fc70ce893c8d842ecad3297eab3e2 attempts to catch the exception thrown by analysis code and reports it. The downside is that if the exception is thrown, no analysis information is available to the user and the wizard. a more elaborate solution is to catch the exception inside the analysis codebase and return a list of problems while still collecting the analysis information for the rest of the to-be-imported projects. Then we could mark the failed projects with an icon or similar and still provide reasonable behaviour for the rest of the projects. Please provide feedback with regard to the current solution (good enough or not) and the ideal case I outlined (to be done this iteration or not). thanks. http://git.eclipse.org/c/m2e/m2e-core.git/commit/?id=11d77c64ab8b97b6d4c664f067c5cd4004986f39 now have the partial analysis result being processed. The projects with failed analysis get to show an error message like the failed scanning does (in the message area above) I've tried to experiment with selection based errors and marking the failed projects with icons, but discarded the idea. Turned out to be too much extra work (given how much lineups ui took time) . maybe next time. Orthogonally to this effort, the error message need some polishing and simplifying (as usual). The current raw exception messages are not fitting well into the messages area and are also not very informative (too detailed) to the average user. IMHO at least |
Created attachment 190257 [details] screenshot see screenshot. after we(I) have added the analysis of projects into the first panel of the import wizard, the errors in the analysis are not correctly recovered from. I need advice on how to proceed in this case: do we just allow people to import the project without jumping to the lifecycle page? Is there some other way for users to recover? is this error "normal" or something that has to be fixed?