java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: testumlaut_ü.test 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.encode(UnixPath.java:147) 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.<init>(UnixPath.java:71) 2016-05-26 22:29:57.400484500 at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281) 2016-05-26 22:29:57.400484500 at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.utils.BambooFiles.resolvePathUnderParent(BambooFiles.java:170) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.v2.build.agent.messages.ArtifactStreams.deserialiseStreamToDir(ArtifactStreams.java:79) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.storeArtifact(ArtifactServlet.java:114) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.doPost(ArtifactServlet.java:100)

Atlassian JIRA | Jaime Silveira [Atlassian] | 6 months ago
  1. 0

    h3. Summary Bamboo is no longer able to handle artifacts whose filenames have an umlaut (¨). It fails to publish artifacts in this case. h3. Environment We can replicate it in Bamboo {{5.12.0-D20160518T090318}} but we cannot replicate in {{5.10-OD-15-001}} (haven't tested in other versions), which shows this has changed. h3. Steps to Reproduce # Create a build plan in Bamboo with a single task: a script task # Add the following code to the task: {{echo Test > testumlaut_ü.test}} #* Notice that the last ‘u’ has an umlaut # Create an artifact definition that includes the generated file (tested with shared artifacts) #* A simply copy pattern like ‘*’ is enough # Run the plan h3. Expected Results The build is successfully run and the ‘testumlaut_ü.test’ is added as an artifact in the build result. h3. Actual Results Though the build is successful, it doesn’t contain any artifacts. The build log shows this: {noformat} error 24-May-2016 15:04:55 Unable to publish artifact [Test]: simple 24-May-2016 15:04:55 The artifact hasn't been successfully published after 13.33 s {noformat} The Bamboo Server logs show this: {noformat} 2016-05-26 22:29:57.397037500 2016-05-26 22:29:57,396 INFO [http-nio-6990-exec-4] [ArtifactServlet] Receiving Artifact [Test] for TEST-TEST-JOB1-2 2016-05-26 22:29:57.400482500 2016-05-26 22:29:57,399 ERROR [http-nio-6990-exec-4] [ArtifactServlet] Exception when storing the artifact 2016-05-26 22:29:57.400483500 java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: testumlaut_ü.test 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.encode(UnixPath.java:147) 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.<init>(UnixPath.java:71) 2016-05-26 22:29:57.400484500 at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281) 2016-05-26 22:29:57.400484500 at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.utils.BambooFiles.resolvePathUnderParent(BambooFiles.java:170) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.v2.build.agent.messages.ArtifactStreams.deserialiseStreamToDir(ArtifactStreams.java:79) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.storeArtifact(ArtifactServlet.java:114) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.doPost(ArtifactServlet.java:100) 2016-05-26 22:29:57.400492500 at javax.servlet.http.HttpServlet.service(HttpServlet.java:648) 2016-05-26 22:29:57.400492500 at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) 2016-05-26 22:29:57.400492500 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291) 2016-05-26 22:29:57.400495500 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) 2016-05-26 22:29:57.400496500 at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:39) {noformat} The agent logs show this: {noformat} 2016-05-24 15:19:22,865 ERROR [0-BAM::Elastic Agent on i-72c963cf::Agent:pool-3-thread-1] [BambooArtifactHttpTransport] Unexpected HTTP status code: HTTP/1.1 500 Internal Server Error 2016-05-24 15:19:22,865 INFO [0-BAM::Elastic Agent on i-72c963cf::Agent:pool-3-thread-1] [AbstractArtifactManager] Handler com.atlassian.bamboo.build.artifact.BambooRemoteArtifactHandler did not publish the artifact 2016-05-24 15:19:22,866 WARN [0-BAM::Elastic Agent on i-72c963cf::Agent:pool-3-thread-1] [AbstractArtifactManager] Unable to publish artifact [test]: {noformat} h3. Notes This is the only invalid character found so far, but there may be others. h3.Workaround Change tasks to generate file names without the ‘umlaut’.

    Atlassian JIRA | 6 months ago | Jaime Silveira [Atlassian]
    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: testumlaut_ü.test 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.encode(UnixPath.java:147) 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.<init>(UnixPath.java:71) 2016-05-26 22:29:57.400484500 at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281) 2016-05-26 22:29:57.400484500 at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.utils.BambooFiles.resolvePathUnderParent(BambooFiles.java:170) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.v2.build.agent.messages.ArtifactStreams.deserialiseStreamToDir(ArtifactStreams.java:79) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.storeArtifact(ArtifactServlet.java:114) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.doPost(ArtifactServlet.java:100)
  2. 0

    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters when using national characters

    Stack Overflow | 3 months ago | Arturas M
    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /home/pi/myFolder/löwen
  3. 0

    GitHub comment 11#77008267

    GitHub | 2 years ago | giray
    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /data/TEST/ab??defg??i????????????????.txt
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    java environment or charset settings that can influence File.getCanonicalPath

    Stack Overflow | 7 months ago | auntyellow
    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /tmp/测试-1ca8f20c3deccbf7aabe625397e2d3
  6. 0

    Java error creating Path from String, does linux limit filenames to 8bit charset

    Stack Overflow | 2 months ago | Paul Taylor
    java.nio.file.InvalidPathException: Malformed input or input contains unmappable characters: /out/K/Kyuss/?And the Circus Leaves Town/09 - Size Queen.mp3

    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.nio.file.InvalidPathException

      Malformed input or input contains unmappable characters: testumlaut_ü.test 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.encode(UnixPath.java:147) 2016-05-26 22:29:57.400483500 at sun.nio.fs.UnixPath.<init>(UnixPath.java:71) 2016-05-26 22:29:57.400484500 at sun.nio.fs.UnixFileSystem.getPath(UnixFileSystem.java:281) 2016-05-26 22:29:57.400484500 at sun.nio.fs.AbstractPath.resolve(AbstractPath.java:53) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.utils.BambooFiles.resolvePathUnderParent(BambooFiles.java:170) 2016-05-26 22:29:57.400489500 at com.atlassian.bamboo.v2.build.agent.messages.ArtifactStreams.deserialiseStreamToDir(ArtifactStreams.java:79) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.storeArtifact(ArtifactServlet.java:114) 2016-05-26 22:29:57.400490500 at com.atlassian.bamboo.agent.messaging.ArtifactServlet.doPost(ArtifactServlet.java:100)

      at javax.servlet.http.HttpServlet.service()
    2. JavaServlet
      HttpServlet.service
      1. javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
      2. javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
      2 frames
    3. Glassfish Core
      ApplicationFilterChain.internalDoFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
      1 frame