java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Hi Team, I am getting error in server while publishing scoverage xml and html report. java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^ at java.util.regex.Pattern.error(Pattern.java:1924) at java.util.regex.Pattern.escape(Pattern.java:2416) at java.util.regex.Pattern.atom(Pattern.java:2164) at java.util.regex.Pattern.sequence(Pattern.java:2097) at java.util.regex.Pattern.expr(Pattern.java:1964) at java.util.regex.Pattern.compile(Pattern.java:1665) at java.util.regex.Pattern.<init>(Pattern.java:1337) at java.util.regex.Pattern.compile(Pattern.java:1022) at java.lang.String.replaceAll(String.java:2162) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.processReport(Scov eragePublisher.java:93) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.perform(ScoverageP ublisher.java:58) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBui ld.java:770) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildStep s(AbstractBuild.java:734) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild. java:683) at hudson.model.Run.execute(Run.java:1765) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) In Scoverage publisher class at line 93 the code is FileUtils.writeStringToFile(f, content.replaceAll("href=\".*" + pattern + "/", "href=\"")); for some reason, exception is thrown at this point and rest code does not execute therfore in jenkins, right side graph and coverage graph for scoverage not working (I guess). Do you know why am I failing or what the problem is? I have used sbt plugin and to deploy on jenkins, used scoverage plugin. Thanks AK
    via by Akhilesh Kumar,
  • Hi, I am getting error in server while publishing scoverage xml and html report. java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^ at java.util.regex.Pattern.error(Pattern.java:1924) at java.util.regex.Pattern.escape(Pattern.java:2416) at java.util.regex.Pattern.atom(Pattern.java:2164) at java.util.regex.Pattern.sequence(Pattern.java:2097) at java.util.regex.Pattern.expr(Pattern.java:1964) at java.util.regex.Pattern.compile(Pattern.java:1665) at java.util.regex.Pattern.<init>(Pattern.java:1337) at java.util.regex.Pattern.compile(Pattern.java:1022) at java.lang.String.replaceAll(String.java:2162) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.processReport(Scov eragePublisher.java:93) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.perform(ScoverageP ublisher.java:58) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBui ld.java:770) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildStep s(AbstractBuild.java:734) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild. java:683) at hudson.model.Run.execute(Run.java:1765) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) In Scoverage publisher class at line 93 the code is FileUtils.writeStringToFile(f, content.replaceAll("href=\".*" + pattern + "/", "href=\"")); for some reason, exception is thrown at this point and rest code does not execute therfore in jenkins, right side graph and coverage graph for scoverage not working (I guess). Do you know why am I failing or what the problem is? I have used sbt plugin and to deploy on jenkins, used scoverage plugin.
    via by Akhilesh Kumar,
  • Hi Team, I am getting error in server while publishing scoverage xml and html report. java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^ at java.util.regex.Pattern.error(Pattern.java:1924) at java.util.regex.Pattern.escape(Pattern.java:2416) at java.util.regex.Pattern.atom(Pattern.java:2164) at java.util.regex.Pattern.sequence(Pattern.java:2097) at java.util.regex.Pattern.expr(Pattern.java:1964) at java.util.regex.Pattern.compile(Pattern.java:1665) at java.util.regex.Pattern.<init>(Pattern.java:1337) at java.util.regex.Pattern.compile(Pattern.java:1022) at java.lang.String.replaceAll(String.java:2162) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.processReport(Scov eragePublisher.java:93) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.perform(ScoverageP ublisher.java:58) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBui ld.java:770) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildStep s(AbstractBuild.java:734) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild. java:683) at hudson.model.Run.execute(Run.java:1765) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) In Scoverage publisher class at line 93 the code is FileUtils.writeStringToFile(f, content.replaceAll("href=\".*" + pattern + "/", "href=\"")); for some reason, exception is thrown at this point and rest code does not execute therfore in jenkins, right side graph and coverage graph for scoverage not working (I guess). Do you know why am I failing or what the problem is? I have used sbt plugin and to deploy on jenkins, used scoverage plugin. Thanks AK
    via by Akhilesh Kumar,
  • Hi, I am getting error in server while publishing scoverage xml and html report. java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^ at java.util.regex.Pattern.error(Pattern.java:1924) at java.util.regex.Pattern.escape(Pattern.java:2416) at java.util.regex.Pattern.atom(Pattern.java:2164) at java.util.regex.Pattern.sequence(Pattern.java:2097) at java.util.regex.Pattern.expr(Pattern.java:1964) at java.util.regex.Pattern.compile(Pattern.java:1665) at java.util.regex.Pattern.<init>(Pattern.java:1337) at java.util.regex.Pattern.compile(Pattern.java:1022) at java.lang.String.replaceAll(String.java:2162) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.processReport(Scov eragePublisher.java:93) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.perform(ScoverageP ublisher.java:58) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBui ld.java:770) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildStep s(AbstractBuild.java:734) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild. java:683) at hudson.model.Run.execute(Run.java:1765) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) In Scoverage publisher class at line 93 the code is FileUtils.writeStringToFile(f, content.replaceAll("href=\".*" + pattern + "/", "href=\"")); for some reason, exception is thrown at this point and rest code does not execute therfore in jenkins, right side graph and coverage graph for scoverage not working (I guess). Do you know why am I failing or what the problem is? I have used sbt plugin and to deploy on jenkins, used scoverage plugin.
    via by Akhilesh Kumar,
    • java.util.regex.PatternSyntaxException: Illegal/unsupported escape sequence near index 31 href=".*scoverage-report\views\html\pages/ ^ at java.util.regex.Pattern.error(Pattern.java:1924) at java.util.regex.Pattern.escape(Pattern.java:2416) at java.util.regex.Pattern.atom(Pattern.java:2164) at java.util.regex.Pattern.sequence(Pattern.java:2097) at java.util.regex.Pattern.expr(Pattern.java:1964) at java.util.regex.Pattern.compile(Pattern.java:1665) at java.util.regex.Pattern.<init>(Pattern.java:1337) at java.util.regex.Pattern.compile(Pattern.java:1022) at java.lang.String.replaceAll(String.java:2162) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.processReport(ScoveragePublisher.java:93) at org.jenkinsci.plugins.scoverage.ScoveragePublisher.perform(ScoveragePublisher.java:58) at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:770) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:734) at hudson.model.Build$BuildExecution.post2(Build.java:183) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:683) at hudson.model.Run.execute(Run.java:1765) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240)

    Users with the same issue

    olle.hallin
    olle.hallin1 times, last one,
    Handemelindo
    Handemelindo1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    osvzs
    osvzs12 times, last one,
    22 more bugmates