Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NullPointerException when attaching a commit to a bug #679

Closed
gitblit opened this issue Aug 12, 2015 · 5 comments
Closed

NullPointerException when attaching a commit to a bug #679

gitblit opened this issue Aug 12, 2015 · 5 comments

Comments

@gitblit
Copy link
Owner

@gitblit gitblit commented Aug 12, 2015

Originally reported on Google Code with ID 383

What steps will reproduce the problem?
1. Create a bug
2. Commit some changes and push to HEAD:refs/for/<bug-number>
3. Go to the web interface and open the bug

What is the expected output? What do you see instead?
Get internal error when opening the link for the bug

What version of the product are you using? On what operating system?
1.4.1

Please provide any additional information below.



2014-03-14 15:55:18 [ERROR] Error attaching this container for rendering: [MarkupContainer
[Component id = panel]]
org.apache.wicket.WicketRuntimeException: Error attaching this container for rendering:
[MarkupContainer [Component id = panel]]
        at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1789)
        at org.apache.wicket.Component.onBeforeRender(Component.java:4001)
        at org.apache.wicket.Component.internalBeforeRender(Component.java:1069)
        at org.apache.wicket.Component.beforeRender(Component.java:1103)
        at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1777)
        at org.apache.wicket.Component.onBeforeRender(Component.java:4001)
        at org.apache.wicket.Component.internalBeforeRender(Component.java:1069)
        at org.apache.wicket.Component.beforeRender(Component.java:1103)
        at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1777)
        at org.apache.wicket.Component.onBeforeRender(Component.java:4001)
        at org.apache.wicket.Page.onBeforeRender(Page.java:1555)
        at com.gitblit.wicket.pages.BasePage.onBeforeRender(BasePage.java:138)
        at com.gitblit.wicket.pages.RepositoryPage.onBeforeRender(RepositoryPage.java:624)
        at org.apache.wicket.Component.internalBeforeRender(Component.java:1069)
        at org.apache.wicket.Component.beforeRender(Component.java:1103)
        at org.apache.wicket.Component.prepareForRender(Component.java:2297)
        at org.apache.wicket.Page.prepareForRender(Page.java:1545)
        at org.apache.wicket.Component.prepareForRender(Component.java:2329)
        at org.apache.wicket.Page.renderPage(Page.java:912)
        at org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.respond(BookmarkablePageRequestTarget.java:261)
        at org.apache.wicket.request.AbstractRequestCycleProcessor.respond(AbstractRequestCycleProcessor.java:105)
        at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1287)
        at org.apache.wicket.RequestCycle.step(RequestCycle.java:1358)
        at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1465)
        at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
        at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:486)
        at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:319)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
        at com.gitblit.servlet.EnforceAuthenticationFilter.doFilter(EnforceAuthenticationFilter.java:86)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:928)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:539)
        at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:298)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:636)
Caused by: java.lang.NullPointerException
        at com.gitblit.wicket.pages.TicketPage$13.populateItem(TicketPage.java:1163)
        at org.apache.wicket.markup.repeater.RefreshingView$1.newItem(RefreshingView.java:114)
        at org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(DefaultItemReuseStrategy.java:71)
        at org.apache.wicket.markup.repeater.DefaultItemReuseStrategy$1.next(DefaultItemReuseStrategy.java:68)
        at org.apache.wicket.markup.repeater.RefreshingView.addItems(RefreshingView.java:189)
        at org.apache.wicket.markup.repeater.RefreshingView.onPopulate(RefreshingView.java:98)
        at org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:131)
        at org.apache.wicket.markup.repeater.AbstractPageableView.onBeforeRender(AbstractPageableView.java:121)
        at org.apache.wicket.Component.internalBeforeRender(Component.java:1069)
        at org.apache.wicket.Component.beforeRender(Component.java:1103)
        at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1777)
        ... 45 more

Reported by ricardo@theclickpro.com on 2014-03-14 19:59:36

@gitblit
Copy link
Owner Author

@gitblit gitblit commented Aug 12, 2015

The version is actually 1.4.0 not 1.4.1 ... sorry for the mistake

Reported by ricardo@theclickpro.com on 2014-03-14 20:00:38

@gitblit
Copy link
Owner Author

@gitblit gitblit commented Aug 12, 2015

This is related to a symlink.  Is there anyway you can zip & ship me the repo for fix
testing?  Or is this sensitive material?

Reported by James.Moger on 2014-03-14 20:04:50

  • Status changed: Accepted
  • Labels added: Milestone-1.4.1

@gitblit
Copy link
Owner Author

@gitblit gitblit commented Aug 12, 2015

Sorry, I'm not able to provide the repositor, but you are right!  The problem is with
a symlink.   Any symlink committed to the repository makes it break.

The line in question is:

RevCommit commit = JGitUtils.getCommit(getRepository(), Constants.R_TICKETS_PATCHSETS
+ ticket.number);

I have changed the line to:

RevCommit commit = JGitUtils.getCommit(getRepository(), Constants.R_TICKET + ticket.number);

That fixed the problem since "refs/tickets/###" doesn't look like a valid reference
in the repository, but  "refs/heads/ticket/###" worked in the command line.


I apologize I did not send you a pull request for the fix.  I locked my self out of
github.

Thanks,

Ricardo



Reported by ricardo@theclickpro.com on 2014-03-15 06:22:12

@gitblit
Copy link
Owner Author

@gitblit gitblit commented Aug 12, 2015

Fix pushed to master.

Reported by James.Moger on 2014-03-17 12:13:07

  • Status changed: Queued

@gitblit
Copy link
Owner Author

@gitblit gitblit commented Aug 12, 2015

v1.4.1 released with a critical security fix.  Please update.

Reported by James.Moger on 2014-03-19 02:15:48

  • Status changed: Done

@gitblit gitblit closed this as completed Aug 12, 2015
@flaix flaix added this to the 1.4.1 milestone Dec 13, 2016
@flaix flaix added this to the 1.4.1 milestone Dec 13, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants