Skip to content

Backend: Job don't run when using parallel:matrix with long variable value

Summary

A customer reporated that when using parallel matrix jobs with long variable value defined under the matrix section, the job will fail to run. When trying to run manually, the error is:

The form contains the following error:
Failed to build the pipeline!

Steps to reproduce

  1. Create a new project.
  2. Use the example .gitlab-ci.yml.
stages:
  - test a
  - test b

demo job a:
  stage: test a
  parallel:
    matrix:
      - VAR_A: '1234567890'
        VAR_B: 'xyz'
        VAR_C: 'someverylongvariablevaluethatcausesthisarbitrarylimitthatisinplacesomewherewithingitlabtobereached'
      - VAR_A: '2345678901'
        VAR_B: 'yzx'
        VAR_C: 'someverylongvariablevaluethatcausesthisarbitrarylimitthatisinplacesomewherewithingitlabtobereached'
      - VAR_A: '3456789012'
        VAR_B: 'zxy'
        VAR_C: 'someverylongvariablevaluethatcausesthisarbitrarylimitthatisinplacesomewherewithingitlabtobereached'
  script:
    - echo ""

demo job b:
  needs:
    - job: demo job a
      artifacts: false
  stage: test b
  script:
    - echo ""
  1. Run the job manually.

Note: Removing the last letter of VAR_C will make it so that the job will run properly

Example Project

https://gitlab.com/jdasmarinas/parallel-pipelines

What is the current bug behavior?

Job doesn't run. When trying to run manually it will give out an error.

What is the expected correct behavior?

Job should run.

Relevant logs and/or screenshots

Screen_Shot_2020-10-08_at_9.40.04_AM

Output of checks

This bug happens on GitLab.com

Customer Information

Update

We surfaced the error in !129326 (merged), which resolves the scope of this issue as explained in #263401 (comment 1739835720).

We are investigating a long term solution to avoid hitting the limit in [matrix job] allow customization of resulting j... (#285853).

Edited by Leaminn Ma