Skip to content

regression between 4.71.0 and 4.72.0 #1859

Description

@ticapix

Hello,

As hinted in #1844 (comment), I experience a regression bug that I reproduced here

https://gitlab.com/pierre-gronlier/debug-ci with the ./test.sh which dl version 4.71.0 and 4.72.0 and run it against:

  • the TBC semver template
  • a simplified version of the template

Minimal .gitlab-ci.yml illustrating the issue

workflow:
  rules:
    - if: $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME =~ $PROD_REF || $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME =~ $INTEG_REF
      when: never
variables:
  PROD_REF: /^(master|main)$/

The error is

  Error attempting to evaluate the following rules:
    rules:
      - if: 'null =~ "/^(master|main)$/" || null =~ null'
  as
  ```javascript
  false || null =~ null

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions