Remove stage default from CI schema
What does this MR do and why?
For #341600 (closed) and #335961 (closed)
The following changes are added to the CI schema for the pipeline editor:
- Updated description for
start_in
keyword, as described in https://docs.gitlab.com/ee/ci/jobs/job_control.html#run-a-job-after-a-delay - Removed
"test"
as a default stage name. Also added aminLength: 1
rule forstage
so it checks that the value is not empty.
Screenshots or screen recordings
stage
Before | After |
---|---|
Before | After |
start_in
How to set up and validate locally
- Enable the
schema_linting
feature flag (rails c
thenFeature.enable(:schema_linting)
) - Go to the Pipeline Editor (CI/CD > Editor)
- If you type
stage
into the editor, it should no longer prompt a default"stage"
value. It should show the error if the user doesn't provide a value. - Typing an incorrect
start_in
value will show the updated description on hover.
Sample .gitlab-ci.yml
content:
stages:
- build
job:
stage: build
when: delayed
start_in: 1 week
script:
echo "Hello World!"
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Mireya Andres