Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
make check-dependent-* only be executed in PRs (#4588)
Browse files Browse the repository at this point in the history
Make check-dependent-* jobs only be executed in PRs instead of both PRs and
master.

Reason 1: The companion is not merged at the same time as the parent PR
([1](paritytech/parity-processbot#347 (comment))),
therefore the pipeline will fail on master since the companion PR is not yet
merged in the other repository. This scenario is demonstrated by the pipeline
of
paritytech/substrate@82cc374.

Reason 2: The job can still fail on master due to a new commit on the companion
PR's repository which was merged after `bot merge` happened, as demonstrated by
the following scheme:

1. Parent PR is merged
2. Companion PR is updated and set to merge in the future
3. In the meantime a new commit is merged into the companion PR repository's
  master branch
4. The `check-dependent-*` job runs on master but, due to the new commit, it
  fails for unrelated reasons

While "Reason 2" can be used as an argument against this PR, in that it would
be useful to know if the integration is failing on master, "Reason 1" should be
taken care of due to this inherent flaw of the current companion build system
design.
  • Loading branch information
joao-paulo-parity authored Dec 27, 2021
1 parent a03f855 commit 138535e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ default:
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs
- if: $CI_COMMIT_REF_NAME == "rococo-v1"

.rules-test-pr: &rules-test-pr
rules:
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs

#### Vault secrets
.vault-secrets: &vault-secrets
secrets:
Expand Down Expand Up @@ -291,6 +295,7 @@ build-malus:
.check-dependent-project: &check-dependent-project
stage: build
<<: *docker-env
<<: *rules-test-pr
<<: *vault-secrets
script:
- git clone
Expand Down

0 comments on commit 138535e

Please sign in to comment.