Nested include has input overwritten if included twice

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

Summary

When composing a CI pipeline with includes and a nested include with inputs is used twice, the inputs will be overwritten. Expected is, that the inputs will stay different, but only the last input is used in the resulting pipeline.

Steps to reproduce

  1. Create a project with a pipeline
  2. Include two different files in that pipeline
  3. In those two files, include the same third file that has an input
  4. Make the input different in both includes

Example Project

Reproducer project

What is the current bug behavior?

The behavior is, that the pipeline prints two times the last input, and does not evaluate the first input. It prints two times SUCCESS.

What is the expected correct behavior?

Each of the inputs should be evaluated: One of the stages should print SUCCESS, the other one FAILURE.

Output of checks

This bug happens on GitLab.com

Edited by 🤖 GitLab Bot 🤖