[Bug][gitextractor] Unable to disable CollectDeployment #7611
Labels
component/plugins
This issue or PR relates to plugins
pr-type/bug-fix
This PR fixes a bug
type/bug
This issue is a bug
Search before asking
What happened
i’d like to disable the gitlab-collectDeployment but having difficulties doing so via environments variables:
this is what I’m using:
ENABLE_SUBTASKS_BY_DEFAULT="gitlab:CollectDeployment:false"
What do you expect to happen
CollectDeployments phase is removed from transform.
How to reproduce
set:
ENABLE_SUBTASKS_BY_DEFAULT="gitlab:CollectDeployment:false
Anything else
we had a look at the source (even v1.0.0-beta6) the Gilab plugin blueprint creation bypasses this function:
https://github.com/apache/incubator-devlake/blob/v1.0.0-beta6/backend/helpers/pluginhelper/api/pipeline_plan.go#L60
The above function utilises the ENABLE_SUBTASKS_BY_DEFAULT to enable or disable subtasks for the plugin. No other part of the code utilises that environment variable.
The Gitlab plugin bypasses MakePipelinePlanTask in the helper by calling MakePipelinePlanSubtasks helper instead which is what is ultimately called by MakePipelinePlanTask:
https://github.com/apache/incubator-devlake/blob/v1.0.0-beta6/backend/plugins/gitlab/api/blueprint_v200.go#L127
Version
v0.21.0@ac4f7fe
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: