When writing tests for SKARA-1385, I found the `csr` command won't force the CheckWorkItem to re-run the check so that the status of the PR body won't be updated.
Erik had mentioned this problem at the comment ofSKARA-1199 . As a workaround, I use the `summary` command along with `csr` in the tests of SKARA-1385 so that the check can re-run and the status of the PR body can be updated.
After diving into the code, I found the method `CheckWorkItem#getMetadata` which is used by `CheckWorkItem#currentCheckValid` doesn't return a new metadata after using the `csr` command. Because the reply mesage of the `csr` command doesn't have a tag to let `CheckWorkItem#getMetadata` identify it. More info: the field `CheckWorkItem#metadataComments` contains the related tags.
I didn't investigate whether other commands have the same issue. But it is good to fix the `csr` command firstly.
Erik had mentioned this problem at the comment of
After diving into the code, I found the method `CheckWorkItem#getMetadata` which is used by `CheckWorkItem#currentCheckValid` doesn't return a new metadata after using the `csr` command. Because the reply mesage of the `csr` command doesn't have a tag to let `CheckWorkItem#getMetadata` identify it. More info: the field `CheckWorkItem#metadataComments` contains the related tags.
I didn't investigate whether other commands have the same issue. But it is good to fix the `csr` command firstly.
- relates to
-
SKARA-1385 Backport MR links to the wrong CSR request
- Resolved
-
SKARA-1199 Enforce maintainer approval in JBS before allowing to integrate backports into updates projects
- Resolved