actions / labeler

An action for automatically labelling pull requests
MIT License
1.98k stars 419 forks source link

Invalid regular expression: (?i): Invalid group #817

Open cjxe opened 2 weeks ago

cjxe commented 2 weeks ago

Description:

When I type (?i) into a regex rule, then the runner throws an error.

Action version:

Latest version.

Platform:

Runner type:

Repro steps:

Add the following rule to labeler.yml:

SOMELABEL:
  - head-branch: '^(?i)(a).*'

Expected behavior:

The error shouldn't be thrown.

Actual behavior:

GitHub Actions runner on ubuntu-latest throw the following error:

The configuration file (path: .github/labeler.yml) was not found locally, fetching via the api
Error: SyntaxError: Invalid regular expression: /^(?i)(a).*/: Invalid group
Error: Invalid regular expression: /^(?i)(a).*/: Invalid group
mahabaleshwars commented 1 week ago

Hello @cjxe, Thank you for creating this issue. We will investigate it and provide feedback as soon as we have some updates.