java.util.regex.PatternSyntaxException: Illegal repetition near index 1 \${$1} ^

  1. 0

    Java Regex building

    Stack Overflow | 2 months ago | Sujatha Kannan
    java.util.regex.PatternSyntaxException: Illegal repetition near index 1 \${$1} ^
  2. 0

    Chatmanager not getting PLAYER_CHAT

    GitHub | 5 years ago | Pirate43
    java.util.regex.PatternSyntaxException: Illegal repetition {lwc\.protect=true}
  3. 0

    Hi there, It appears the "Poll Exclude File(s)" section of the Perforce plugin doesn't support build parameters. In my Perforce view configuration I'm quite happily using something like: //mydepot/${branch}/Engine/Include/Macros.h "//workspace/Engine/Include/Macros.h" where "branch" is a string parameter specified under the "This build is parameterized" option. However, if I enter the following in "Poll Exclude File(s)": //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt I get: {code} ERROR: Failed to record SCM polling java.util.regex.PatternSyntaxException: Illegal repetition near index 8 //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt ^ at java.util.regex.Pattern.error(Unknown Source) at java.util.regex.Pattern.closure(Unknown Source) at java.util.regex.Pattern.sequence(Unknown Source) at java.util.regex.Pattern.expr(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at java.util.regex.Pattern.<init>(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at hudson.plugins.perforce.PerforceSCM.doesFilenameMatchP4Pattern(PerforceSCM.java:1112) at hudson.plugins.perforce.PerforceSCM.doesFilenameMatchAnyP4Pattern(PerforceSCM.java:1100) at hudson.plugins.perforce.PerforceSCM.isChangelistExcluded(PerforceSCM.java:1079) at hudson.plugins.perforce.PerforceSCM.getCurrentDepotRevisionState(PerforceSCM.java:1020) at hudson.plugins.perforce.PerforceSCM.compareRemoteRevisionWith(PerforceSCM.java:900) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject.poll(AbstractProject.java:1326) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:420) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:449) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) {code} Can this be fixed please? Regards, Tom.

    Jenkins JIRA | 5 years ago | Thomas Fields
    java.util.regex.PatternSyntaxException: Illegal repetition near index 8 //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt ^
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    A workspace mapping containing a variable reference (example and log output below) will fail to poll for changes due to the variable not getting resolved. Manually running the build will properly resolve the variable and update the workspace view. However, when a poll is executed, the workspace view is replaced with the raw template that does not have the variable's value inserted. The variable is defined using the standard Jenkins environment variable plugin. Example: //tools/sun/jdk1.8.0_45/${JAVA_PLATFORM}/... //CLIENT_NAME/tools/${JAVA_PLATFORM}/... Poll Log: {code} Started on Jul 22, 2015 3:27:00 PM Looking for changes... Using master Read ClientSpec from: //x/java/JRX/trunk/p4client.functest.view Using master perforce client: jenkins-rxa-x64-trunk-install-windows-8-64 Read ClientSpec from: //x/java/JRX/trunk/p4client.functest.view Warning: Client Spec line invalid, ignoring. (View:) Latest submitted change selected by workspace is 889214 ERROR: Failed to record SCM polling for hudson.model.FreeStyleProject@37d2f[rxa-x64-trunk-install-windows-8-64] java.util.regex.PatternSyntaxException: Illegal repetition near index 44 //x/java/JRX/trunk/testFunc/xinstall/tools/\${JAVA_PLATFORM}/(.*) ^ at java.util.regex.Pattern.error(Unknown Source) at java.util.regex.Pattern.closure(Unknown Source) at java.util.regex.Pattern.sequence(Unknown Source) at java.util.regex.Pattern.expr(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at java.util.regex.Pattern.<init>(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at hudson.plugins.perforce.PerforceSCMHelper.getTokenPattern(PerforceSCMHelper.java:218) at hudson.plugins.perforce.PerforceSCMHelper.doesPathMatchView(PerforceSCMHelper.java:198) at hudson.plugins.perforce.PerforceSCMHelper.mapToWorkspace(PerforceSCMHelper.java:184) at com.tek42.perforce.parse.Changes.getWorkspacePathForFile(Changes.java:98) at com.tek42.perforce.parse.Changes.calculateWorkspacePaths(Changes.java:92) at com.tek42.perforce.parse.Changes.getChangelist(Changes.java:74) at hudson.plugins.perforce.PerforceSCM.getCurrentDepotRevisionState(PerforceSCM.java:1354) at hudson.plugins.perforce.PerforceSCM.compareRemoteRevisionWith(PerforceSCM.java:1234) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:357) at hudson.scm.SCM.poll(SCM.java:374) at hudson.model.AbstractProject._poll(AbstractProject.java:1427) at hudson.model.AbstractProject.poll(AbstractProject.java:1330) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:466) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:495) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) {code}

    Jenkins JIRA | 1 year ago | Jason Archer
    java.util.regex.PatternSyntaxException: Illegal repetition near index 44 //x/java/JRX/trunk/testFunc/xinstall/tools/\${JAVA_PLATFORM}/(.*) ^
  6. 0

    Hi there, It appears the "Poll Exclude File(s)" section of the Perforce plugin doesn't support build parameters. In my Perforce view configuration I'm quite happily using something like: //mydepot/${branch}/Engine/Include/Macros.h "//workspace/Engine/Include/Macros.h" where "branch" is a string parameter specified under the "This build is parameterized" option. However, if I enter the following in "Poll Exclude File(s)": //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt I get: {code} ERROR: Failed to record SCM polling java.util.regex.PatternSyntaxException: Illegal repetition near index 8 //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt ^ at java.util.regex.Pattern.error(Unknown Source) at java.util.regex.Pattern.closure(Unknown Source) at java.util.regex.Pattern.sequence(Unknown Source) at java.util.regex.Pattern.expr(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at java.util.regex.Pattern.<init>(Unknown Source) at java.util.regex.Pattern.compile(Unknown Source) at hudson.plugins.perforce.PerforceSCM.doesFilenameMatchP4Pattern(PerforceSCM.java:1112) at hudson.plugins.perforce.PerforceSCM.doesFilenameMatchAnyP4Pattern(PerforceSCM.java:1100) at hudson.plugins.perforce.PerforceSCM.isChangelistExcluded(PerforceSCM.java:1079) at hudson.plugins.perforce.PerforceSCM.getCurrentDepotRevisionState(PerforceSCM.java:1020) at hudson.plugins.perforce.PerforceSCM.compareRemoteRevisionWith(PerforceSCM.java:900) at hudson.scm.SCM._compareRemoteRevisionWith(SCM.java:356) at hudson.scm.SCM.poll(SCM.java:373) at hudson.model.AbstractProject.poll(AbstractProject.java:1326) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:420) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:449) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) {code} Can this be fixed please? Regards, Tom.

    Jenkins JIRA | 5 years ago | Thomas Fields
    java.util.regex.PatternSyntaxException: Illegal repetition near index 8 //mydepot/${branch}/Engine/Tools/Source/StripELF/Readme_e.txt ^

  1. davidvanlaatum 2 times, last 3 months ago
  2. mortalman7 1 times, last 4 months ago
  3. Christopher 5 times, last 6 months ago
6 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.util.regex.PatternSyntaxException

    Illegal repetition near index 1 \${$1} ^

    at java.util.regex.Pattern.error()
  2. Java RT
    Pattern.compile
    1. java.util.regex.Pattern.error(Unknown Source)
    2. java.util.regex.Pattern.closure(Unknown Source)
    3. java.util.regex.Pattern.sequence(Unknown Source)
    4. java.util.regex.Pattern.expr(Unknown Source)
    5. java.util.regex.Pattern.compile(Unknown Source)
    6. java.util.regex.Pattern.<init>(Unknown Source)
    7. java.util.regex.Pattern.compile(Unknown Source)
    7 frames
  3. myUtil
    ReplaceString.main
    1. myUtil.ReplaceString.fetchKeyword(ReplaceString.java:70)
    2. myUtil.ReplaceString.main(ReplaceString.java:20)
    2 frames