Build: use is_active
method to know if the build should be skipped
#8179
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently we are using only
project.skip
to know if the build for thisparticular project has to be skipped after the task was triggered. However, if
the if the project belongs to an organization and the organization is disabled
those builds already queued will be built.
This commit uses
is_active
forproject.skip
field in the API response, thattakes care of this case.
This helps us if we found that an organization already triggered many builds
and we need to cancel all of them. With this change, just by doing
organization.disable=True
will make kill them all at built time instead ofprocessing them.