java.net.URISyntaxException: Illegal character in path at index 31: file://attachment/xwiki.Main.My Page.commentsView.jpg

XWiki.org JIRA | Reto Hotz | 8 years ago
  1. 0

    I want to export a page as HTML. - The page contains one attachment: commentsView.jpg - The name of the page contains a whitespace: "My Page" I know that the exception is thrown because of the whitespace in the pagename. But people are used to create such pages. And XWiki allows it. During the (successfull) export I get the following exception: java.net.URISyntaxException: Illegal character in path at index 31: file://attachment/xwiki.Main.My Page.commentsView.jpg at java.net.URI$Parser.fail(URI.java:2816) at java.net.URI$Parser.checkChars(URI.java:2989) at java.net.URI$Parser.parseHierarchical(URI.java:3073) at java.net.URI$Parser.parse(URI.java:3021) at java.net.URI.<init>(URI.java:578) at com.xpn.xwiki.web.ExportURLFactory.createAttachmentURL(ExportURLFactory.java:241) at com.xpn.xwiki.web.ExportURLFactory.createAttachmentURL(ExportURLFactory.java:255) at com.xpn.xwiki.doc.XWikiDocument.getAttachmentURL(XWikiDocument.java:757) at com.xpn.xwiki.api.Document.getAttachmentURL(Document.java:436) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74) at org.apache.velocity.runtime.directive.Foreach.render(Foreach.java:448) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:608) at sun.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596) at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:608) at sun.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295) at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203) at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88) at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178) at org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143) at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107) at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596) at com.xpn.xwiki.export.html.HtmlPackager.renderDocument(HtmlPackager.java:177) at com.xpn.xwiki.export.html.HtmlPackager.renderDocuments(HtmlPackager.java:230) at com.xpn.xwiki.export.html.HtmlPackager.export(HtmlPackager.java:270) at com.xpn.xwiki.web.ExportAction.exportHTML(ExportAction.java:170) at com.xpn.xwiki.web.ExportAction.render(ExportAction.java:59) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:216) at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:115) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at javax.servlet.http.HttpServlet.service(HttpServlet.java:627) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) at com.xpn.xwiki.web.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:287) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) at com.xpn.xwiki.web.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:875) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689) at java.lang.Thread.run(Thread.java:595)

    XWiki.org JIRA | 8 years ago | Reto Hotz
    java.net.URISyntaxException: Illegal character in path at index 31: file://attachment/xwiki.Main.My Page.commentsView.jpg
  2. 0

    problem with parent directory name while deploying mobicents.sar

    Google Groups | 8 years ago | Sachin Parnami
    java.net.URISyntaxException: Illegal character in path at index 22: file:/SLEE AS/jboss-4.2.2.GA/server/default/deploy/mobicents.sar/
  3. 0

    Exchange 2007 Web Services: Generate the JAVA interface

    microsoft.com | 1 year ago
    java.net.URISyntaxException: Illegal character in path at index 18: file:/C:/Documents and Settings/****/Desktop/****/axis2-1.5.1/bin/Services.wsdl
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Exchange 2007 Web Services: Generate the JAVA interface

    microsoft.com | 1 year ago
    java.net.URISyntaxException: Illegal character in path at index 18: file:/C:/Documents and Settings/****/Desktop/****/axis2-1.5.1/bin/Services.wsdl
  6. 0

    Exchange 2007 Web Services: Generate the JAVA interface

    microsoft.com | 4 months ago
    java.net.URISyntaxException: Illegal character in path at index 18: file:/C:/Documents and Settings/****/Desktop/****/axis2-1.5.1/bin/Services.wsdl

  1. tfr 1 times, last 6 months ago
  2. muffinmannen 1 times, last 8 months ago
36 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.net.URISyntaxException

    Illegal character in path at index 31: file://attachment/xwiki.Main.My Page.commentsView.jpg

    at java.net.URI$Parser.fail()
  2. Java RT
    URI.<init>
    1. java.net.URI$Parser.fail(URI.java:2816)
    2. java.net.URI$Parser.checkChars(URI.java:2989)
    3. java.net.URI$Parser.parseHierarchical(URI.java:3073)
    4. java.net.URI$Parser.parse(URI.java:3021)
    5. java.net.URI.<init>(URI.java:578)
    5 frames
  3. com.xpn.xwiki
    Document.getAttachmentURL
    1. com.xpn.xwiki.web.ExportURLFactory.createAttachmentURL(ExportURLFactory.java:241)
    2. com.xpn.xwiki.web.ExportURLFactory.createAttachmentURL(ExportURLFactory.java:255)
    3. com.xpn.xwiki.doc.XWikiDocument.getAttachmentURL(XWikiDocument.java:757)
    4. com.xpn.xwiki.api.Document.getAttachmentURL(Document.java:436)
    4 frames
  4. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    4. java.lang.reflect.Method.invoke(Method.java:585)
    4 frames
  5. Apache Velocity
    SimpleNode.render
    1. org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295)
    2. org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245)
    3. org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203)
    4. org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294)
    5. org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    6. org.apache.velocity.runtime.directive.Foreach.render(Foreach.java:448)
    7. org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    8. org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    9. org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88)
    10. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    10 frames
  6. org.xwiki.velocity
    DefaultVelocityEngine.evaluate
    1. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178)
    2. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143)
    2 frames
  7. com.xpn.xwiki
    XWiki.parseTemplate
    1. com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107)
    2. com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596)
    3. com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:608)
    3 frames
  8. Java RT
    Method.invoke
    1. sun.reflect.GeneratedMethodAccessor146.invoke(Unknown Source)
    2. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    3. java.lang.reflect.Method.invoke(Method.java:585)
    3 frames
  9. Apache Velocity
    SimpleNode.render
    1. org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295)
    2. org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245)
    3. org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203)
    4. org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294)
    5. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    6. org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194)
    7. org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    8. org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    9. org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88)
    10. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    10 frames
  10. org.xwiki.velocity
    DefaultVelocityEngine.evaluate
    1. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178)
    2. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143)
    2 frames
  11. com.xpn.xwiki
    XWiki.parseTemplate
    1. com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107)
    2. com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596)
    3. com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:608)
    3 frames
  12. Java RT
    Method.invoke
    1. sun.reflect.GeneratedMethodAccessor146.invoke(Unknown Source)
    2. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    3. java.lang.reflect.Method.invoke(Method.java:585)
    3 frames
  13. Apache Velocity
    SimpleNode.render
    1. org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:295)
    2. org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:245)
    3. org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:203)
    4. org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:294)
    5. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    6. org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:194)
    7. org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:170)
    8. org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    9. org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:88)
    10. org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:74)
    11. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    12. org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:107)
    13. org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:318)
    13 frames
  14. org.xwiki.velocity
    DefaultVelocityEngine.evaluate
    1. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:178)
    2. org.xwiki.velocity.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:143)
    2 frames
  15. com.xpn.xwiki
    XWikiAction.execute
    1. com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:107)
    2. com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1596)
    3. com.xpn.xwiki.export.html.HtmlPackager.renderDocument(HtmlPackager.java:177)
    4. com.xpn.xwiki.export.html.HtmlPackager.renderDocuments(HtmlPackager.java:230)
    5. com.xpn.xwiki.export.html.HtmlPackager.export(HtmlPackager.java:270)
    6. com.xpn.xwiki.web.ExportAction.exportHTML(ExportAction.java:170)
    7. com.xpn.xwiki.web.ExportAction.render(ExportAction.java:59)
    8. com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:216)
    9. com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:115)
    9 frames
  16. struts
    ActionServlet.doGet
    1. org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
    2. org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
    3. org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
    4. org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
    4 frames
  17. JavaServlet
    HttpServlet.service
    1. javax.servlet.http.HttpServlet.service(HttpServlet.java:627)
    2. javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
    2 frames
  18. Glassfish Core
    ApplicationFilterChain.doFilter
    1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
    2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
    2 frames
  19. com.xpn.xwiki
    SavedRequestRestorerFilter.doFilter
    1. com.xpn.xwiki.web.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:287)
    1 frame
  20. Glassfish Core
    ApplicationFilterChain.doFilter
    1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
    2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
    2 frames
  21. com.xpn.xwiki
    SetCharacterEncodingFilter.doFilter
    1. com.xpn.xwiki.web.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112)
    1 frame
  22. Glassfish Core
    CoyoteAdapter.service
    1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
    2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
    3. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
    4. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
    5. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
    6. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
    7. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
    8. org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
    8 frames
  23. Grizzly HTTP
    LeaderFollowerWorkerThread.runIt
    1. org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:875)
    2. org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
    3. org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
    4. org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
    4 frames
  24. Tomcat Util
    ThreadPool$ControlRunnable.run
    1. org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
    1 frame
  25. Java RT
    Thread.run
    1. java.lang.Thread.run(Thread.java:595)
    1 frame