My favorites | Sign in
Project Home Downloads Wiki Issues Source
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 773: Sidebyside on patch produces Internal Application Error in patchScript
4 people starred this issue and may be notified of changes. Back to list
Status:  Duplicate
Merged:  issue 786
Owner:  ----
Closed:  May 2011
Cc:  mf...@codeaurora.org


Sign in to add a comment
 
Reported by ni...@codeaurora.org, Nov 9, 2010
Affected Version: 2.1.5

What steps will reproduce the problem?
None yet.

What is the expected output? 
Gerrit to display the sidebyside diff of the patch.

What do you see instead?
Gerrit Internal Application Error.

Please provide any additional information below.
1. I am able to pull that change and see the source thru git
2. The file in question is an "A" (added) file
3. Gitweb shows the file ok too


[2010-11-09 08:45:35,458] ERROR / : Error in patchScript
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 2
        at org.eclipse.jgit.util.IntList.get(IntList.java:82)
        at com.google.gerrit.server.patch.Text.getLineEnd(Text.java:172)
        at com.google.gerrit.server.patch.Text.getLines(Text.java:153)
        at com.google.gerrit.server.patch.Text.getLine(Text.java:144)
        at com.google.gerrit.httpd.rpc.patch.PatchScriptBuilder.packContent(PatchScriptBuilder.java:321)
        at com.google.gerrit.httpd.rpc.patch.PatchScriptBuilder.toPatchScript(PatchScriptBuilder.java:166)
        at com.google.gerrit.httpd.rpc.patch.PatchScriptFactory.call(PatchScriptFactory.java:156)
        at com.google.gerrit.httpd.rpc.patch.PatchScriptFactory.call(PatchScriptFactory.java:60)
        at com.google.gerrit.httpd.rpc.Handler.to(Handler.java:65)
        at com.google.gerrit.httpd.rpc.patch.PatchDetailServiceImpl.patchScript(PatchDetailServiceImpl.java:101)
        at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at com.google.gwtjsonrpc.server.MethodHandle.invoke(MethodHandle.java:91)
        at com.google.gwtjsonrpc.server.JsonServlet.doService(JsonServlet.java:382)
        at com.google.gwtjsonrpc.server.JsonServlet.service(JsonServlet.java:268)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
        at com.google.inject.servlet.ServletDefinition.doService(ServletDefinition.java:216)
        at com.google.inject.servlet.ServletDefinition.service(ServletDefinition.java:141)
        at com.google.inject.servlet.ManagedServletPipeline.service(ManagedServletPipeline.java:93)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:63)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.gwtexpui.server.CacheControlFilter.doFilter(CacheControlFilter.java:76)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.gerrit.httpd.RequireSslFilter.doFilter(RequireSslFilter.java:68)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.gerrit.httpd.RequestCleanupFilter.doFilter(RequestCleanupFilter.java:54)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:134)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at com.google.inject.servlet.ManagedFilterPipeline.dispatch(ManagedFilterPipeline.java:122)
        at com.google.inject.servlet.GuiceFilter.doFilter(GuiceFilter.java:110)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1190)
        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:424)
        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:931)
        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:361)
        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:867)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113)
        at org.eclipse.jetty.server.Server.handle(Server.java:337)
        at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:581)
        at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1020)
        at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:775)
        at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:228)
        at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:417)
        at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:474)
        at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:437)
        at java.lang.Thread.run(Thread.java:619)
Nov 9, 2010
#1 nas...@chromium.org
(No comment was entered for this change.)
Cc: mf...@codeaurora.org
Nov 9, 2010
#2 nas...@chromium.org
I just noticed that I only get an error if I diff with the base change.  Diffing any two patchsets works as expected. This file was added in this commit, so trying to view the full added file is what gives this error.

gitweb also reports this when looking at this commit:
[copied from <filename> with 78% similarity, mode: 0644]

Not sure if JGit is trying to do something special and breaking.
Dec 15, 2010
#3 nick.mu...@gmail.com
I'm also seeing this exact same trace on my high-traffic 2.1.5 server.
May 20, 2011
Project Member #4 nas...@grainawi.org
(No comment was entered for this change.)
Status: Duplicate
Mergedinto: 786
Sign in to add a comment

Powered by Google Project Hosting