Reviewing Checks
This document covers the steps to review a new check before it is merged to the main branch.
Prerequisites
- Pipeline for the MR must succeed in order to create the execution environment image.
- A GitLab environment running an affected version for the check. The merge request should include steps to imitate the check requirements.
Steps
- Make sure you have the latest updates for Detective locally.
- From
gitlab-detective/frontend, runuv run detective.pyto start Detective. - When asked
Please specify the full path to the execution environment image:enter the appropriate image tag, for exampleregistry.gitlab.com/gitlab-com/support/toolbox/gitlab-detective:MR-109-1185is the image for MR-109. Available images can be found under the container registry. - Once the job completes, confirm the check was run and if it passed or failed.
- Provide feedback in the merge request as necessary
Troubleshooting
Task is skipped
If the task run shows as skipped, then the environment does not match what is required for the check to run.
For example, if a check is only valid up to version 16.4, but you tested on version 16.5, the check will be skipped.
TASK [A push rule's file_name_regex value is too long]
skipped: [gitlab-16-11]
To fix this, run the test against a version that falls within the version.started and version.fixed values of the check.
Task is not shown in the list of run checks
If you do not see the task listed at all, make sure you are using the right execution environment image tag. Only the image associated with the code change will have the task built into the playbook.