| Summary: | 500 error when merge conflicts with local change | ||
|---|---|---|---|
| Product: | [ECD] Orion | Reporter: | John Arthorne <john.arthorne> |
| Component: | Client | Assignee: | Malgorzata Janczarska <malgorzata.tomczyk> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | malgorzata.tomczyk, tomasz.zarna |
| Version: | 0.2 | Flags: | tomasz.zarna:
review+
|
| Target Milestone: | 0.2 | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| Whiteboard: | |||
*** Bug 348721 has been marked as a duplicate of this bug. *** The message Gosia showed me should do the job. done |
I have a modified (unstaged) file in my working tree. I attempted to merge incoming changes that include changes to that file. The server returns a 500 error and no error message is shown to the user. In the debugger I was able to capture the stack trace of the real exception on the server that shows it is a checkout conflict. This should not come back to the user as a 500 error but instead a more helpful message about the conflict. org.eclipse.jgit.api.errors.JGitInternalException: Exception caught during execution of merge command. org.eclipse.jgit.errors.CheckoutConflictException: Checkout conflict with files: bundles/org.eclipse.orion.client.core/static/js/commands.js at org.eclipse.jgit.api.MergeCommand.call(MergeCommand.java:251) at org.eclipse.orion.server.git.servlets.GitCommitHandlerV1.merge(GitCommitHandlerV1.java:361) at org.eclipse.orion.server.git.servlets.GitCommitHandlerV1.handlePost(GitCommitHandlerV1.java:317) at org.eclipse.orion.server.git.servlets.GitCommitHandlerV1.handleRequest(GitCommitHandlerV1.java:69) at org.eclipse.orion.server.git.servlets.GitCommitHandlerV1.handleRequest(GitCommitHandlerV1.java:1) at org.eclipse.orion.server.git.servlets.GitHandlerV1.handleRequest(GitHandlerV1.java:57) at org.eclipse.orion.server.git.servlets.GitHandlerV1.handleRequest(GitHandlerV1.java:1) at org.eclipse.orion.server.git.servlets.ServletGitHandler.handleRequest(ServletGitHandler.java:49) at org.eclipse.orion.server.git.servlets.ServletGitHandler.handleRequest(ServletGitHandler.java:1) at org.eclipse.orion.server.git.servlets.GitServlet.doGet(GitServlet.java:39) at org.eclipse.orion.server.git.servlets.GitServlet.doPost(GitServlet.java:57) This gets turned into a 500 error by GitCommitHandlerV1#merge: } catch (JGitInternalException e) { return statusHandler.handleRequest(request, response, new ServerStatus(IStatus.ERROR, HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "An error occured when merging.", e.getCause())); }