java.net.URISyntaxException: Illegal character in path at index 18

Splash Forums PrettyFaces Users java.net.URISyntaxException: Illegal character in path at index 18

This topic contains 4 replies, has 2 voices, and was last updated by  Christian Kaltepoth 6 years, 10 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #17837

    EugeneV
    Participant

    When app server path contains white space, I am getting the following error:

    Caused by: java.net.URISyntaxException: Illegal character in path at index 18: vfszip:/C:/Program Files/jbdevstudio/jboss-eap/jboss-as/server/default/deploy/perf_crest.war/WEB-INF/lib/richfaces-core-impl-4.0.0.20101110-M4.jar/META-INF/faces-config.xml

    at java.net.URI$Parser.fail(URI.java:2809)

    at java.net.URI$Parser.checkChars(URI.java:2982)

    at java.net.URI$Parser.parseHierarchical(URI.java:3066)

    at java.net.URI$Parser.parse(URI.java:3014)

    at java.net.URI.<init>(URI.java:578)

    at java.net.URL.toURI(URL.java:918)

    at com.ocpsoft.pretty.faces.el.resolver.FacesConfigBeanNameResolver.getFacesConfigFiles(FacesConfigBeanNameResolver.java:143)

    #20485

    Thanks a lot for reporting this. I’ll have a look at it.

    #20486

    I took a look at this issue and it was a PrettyFaces bug. URLs containing spaces are not valid regarding RFC 2396 and so we cannot build an URI from them.

    I fixed this and you can try if the latest snapshot of the development version works for you:

    If you are using Maven, just set the version to 3.1.1-SNAPSHOT:

    <dependency>
    <groupId>com.ocpsoft</groupId>
    <artifactId>prettyfaces-jsf2</artifactId>
    <version>3.1.1-SNAPSHOT</version>
    </dependency>

    Please make also sure that you have the OcpSoft Maven Repository in your pom.xml:

    <repository>
    <id>ocpsoft</id>
    <name>OcpSoft</name>
    <url>http://ocpsoft.com/repository/</url>
    <releases>
    <enabled>true</enabled>
    </releases>
    <snapshots>
    <enabled>true</enabled>
    </snapshots>
    </repository>

    You can also directly download the latest snapshot here.

    If you don’t want to use the annotation support of PrettyFaces, you could also stay with the current stable version and disable the annotation scanning by adding the following to your web.xml:

    <context-param>
    <param-name>com.ocpsoft.pretty.BASE_PACKAGES</param-name>
    <param-value>none</param-value>
    </context-param>

    If you have any other problems with PrettyFaces, please let us know! :-)

    #20487

    EugeneV
    Participant

    Thanks! I just disabled the annotation scanning for now.

    #20488

    Any chance that you could try the snapshots? Just to make this get fixed in the upcoming release?

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

Comments are closed.