java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy

Jenkins JIRA | Bartosz Kaczorek | 2 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Add projectRoot option to Cobertura reporter

    GitHub | 2 years ago | bartoszkaczorek
    java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy
  2. 0

    The issue happens when trying to publish cobertura-coverage.xml report with relative paths i.e.: {code:xml} ... <sources> <source>C:\Users\myUser\.jenkins\workspace\SomeWorkspaceName\SomeProject\aaa\bbb\ccc\ddd </sources> ... ... <class name="SomeFile.js" filename="..\..\..\..\..\SomeProject\xxx\yyy\SomeFile.js /> ... {code} It's causing below errors: {code:java} 16:33:58 ERROR: ERROR: Failure to paint C:\Users\myUser\.jenkins\workspace\SomeWorkspaceName\SomeProject\aaa\bbb\ccc\ddd\..\..\..\..\..\SomeProject\xxx\yyy\SomeFile.js to C:\Users\myUser\.jenkins\jobs\SomeWorkspaceName\cobertura 16:33:58 java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy 16:33:58 at hudson.FilePath.mkdirs(FilePath.java:1164) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.paintSourceCode(SourceCodePainter.java:62) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:135) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:30) 16:33:58 at hudson.FilePath.act(FilePath.java:991) 16:33:58 at hudson.FilePath.act(FilePath.java:969) 16:33:58 at hudson.plugins.cobertura.CoberturaPublisher.perform(CoberturaPublisher.java:403) 16:33:58 at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:726) 16:33:58 at hudson.model.Build$BuildExecution.post2(Build.java:185) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:671) 16:33:58 at hudson.model.Run.execute(Run.java:1769) 16:33:58 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 16:33:58 at hudson.model.ResourceController.execute(ResourceController.java:98) 16:33:58 at hudson.model.Executor.run(Executor.java:374) {code} See also related issue on intern github page: [https://github.com/theintern/intern/issues/504]

    Jenkins JIRA | 2 years ago | Bartosz Kaczorek
    java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy
  3. 0

    The issue happens when trying to publish cobertura-coverage.xml report with relative paths i.e.: {code:xml} ... <sources> <source>C:\Users\myUser\.jenkins\workspace\SomeWorkspaceName\SomeProject\aaa\bbb\ccc\ddd </sources> ... ... <class name="SomeFile.js" filename="..\..\..\..\..\SomeProject\xxx\yyy\SomeFile.js /> ... {code} It's causing below errors: {code:java} 16:33:58 ERROR: ERROR: Failure to paint C:\Users\myUser\.jenkins\workspace\SomeWorkspaceName\SomeProject\aaa\bbb\ccc\ddd\..\..\..\..\..\SomeProject\xxx\yyy\SomeFile.js to C:\Users\myUser\.jenkins\jobs\SomeWorkspaceName\cobertura 16:33:58 java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy 16:33:58 at hudson.FilePath.mkdirs(FilePath.java:1164) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.paintSourceCode(SourceCodePainter.java:62) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:135) 16:33:58 at hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:30) 16:33:58 at hudson.FilePath.act(FilePath.java:991) 16:33:58 at hudson.FilePath.act(FilePath.java:969) 16:33:58 at hudson.plugins.cobertura.CoberturaPublisher.perform(CoberturaPublisher.java:403) 16:33:58 at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:726) 16:33:58 at hudson.model.Build$BuildExecution.post2(Build.java:185) 16:33:58 at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:671) 16:33:58 at hudson.model.Run.execute(Run.java:1769) 16:33:58 at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) 16:33:58 at hudson.model.ResourceController.execute(ResourceController.java:98) 16:33:58 at hudson.model.Executor.run(Executor.java:374) {code} See also related issue on intern github page: [https://github.com/theintern/intern/issues/504]

    Jenkins JIRA | 2 years ago | Bartosz Kaczorek
    java.io.IOException: Failed to mkdirs: C:\Users\SomeProject\xxx\yyy
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    I tried using "*Check out to a sub-directory*" option in Git SCM configuration with absolute path to required directory. My hope was that word "*sub-directory*" is just a hint for default behaviour until absolute path is specified. But it didn't work: {quote} java.io.IOException: Failed to mkdirs: /path/to/directory/jenkins/has/required/permissions/for/ at hudson.FilePath.mkdirs(FilePath.java:1164) at hudson.plugins.git.GitSCM.createClient(GitSCM.java:636) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:978) at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:129) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408) Notifying upstream projects of job completion {quote} I'm using environment where all (chained and inter-related) jobs share common (absolute) local Git repositories. h2. Proposed solution The same field "*Check out to a sub-directory*" can be renamed into "*Check out to a directory*" with explanation that unless path is absolute, the specified directory is relative to workspace.

    Jenkins JIRA | 2 years ago | Alexey Pakseykin
    java.io.IOException: Failed to mkdirs: /path/to/directory/jenkins/has/required/permissions/for/
  6. 0

    I tried using "*Check out to a sub-directory*" option in Git SCM configuration with absolute path to required directory. My hope was that word "*sub-directory*" is just a hint for default behaviour until absolute path is specified. But it didn't work: {quote} java.io.IOException: Failed to mkdirs: /path/to/directory/jenkins/has/required/permissions/for/ at hudson.FilePath.mkdirs(FilePath.java:1164) at hudson.plugins.git.GitSCM.createClient(GitSCM.java:636) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:978) at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:129) at hudson.scm.SCM.checkout(SCM.java:485) at hudson.model.AbstractProject.checkout(AbstractProject.java:1277) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:610) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:532) at hudson.model.Run.execute(Run.java:1741) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:98) at hudson.model.Executor.run(Executor.java:408) Notifying upstream projects of job completion {quote} I'm using environment where all (chained and inter-related) jobs share common (absolute) local Git repositories. h2. Proposed solution The same field "*Check out to a sub-directory*" can be renamed into "*Check out to a directory*" with explanation that unless path is absolute, the specified directory is relative to workspace.

    Jenkins JIRA | 2 years ago | Alexey Pakseykin
    java.io.IOException: Failed to mkdirs: /path/to/directory/jenkins/has/required/permissions/for/

    3 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.io.IOException

      Failed to mkdirs: C:\Users\SomeProject\xxx\yyy

      at hudson.FilePath.mkdirs()
    2. Hudson
      FilePath.mkdirs
      1. hudson.FilePath.mkdirs(FilePath.java:1164)
      1 frame
    3. hudson.plugins.cobertura
      SourceCodePainter.invoke
      1. hudson.plugins.cobertura.renderers.SourceCodePainter.paintSourceCode(SourceCodePainter.java:62)
      2. hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:135)
      3. hudson.plugins.cobertura.renderers.SourceCodePainter.invoke(SourceCodePainter.java:30)
      3 frames
    4. Hudson
      FilePath.act
      1. hudson.FilePath.act(FilePath.java:991)
      2. hudson.FilePath.act(FilePath.java:969)
      2 frames
    5. hudson.plugins.cobertura
      CoberturaPublisher.perform
      1. hudson.plugins.cobertura.CoberturaPublisher.perform(CoberturaPublisher.java:403)
      1 frame
    6. Hudson
      Executor.run
      1. hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      2. hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
      3. hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:726)
      4. hudson.model.Build$BuildExecution.post2(Build.java:185)
      5. hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:671)
      6. hudson.model.Run.execute(Run.java:1769)
      7. hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      8. hudson.model.ResourceController.execute(ResourceController.java:98)
      9. hudson.model.Executor.run(Executor.java:374)
      9 frames