This is an automated email from the ASF dual-hosted git repository. klesh pushed a commit to branch kw-7021-unable-to-trigger-projects-with-webhooks-only in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
commit 287446baa3464d8af791186f5a71021584628896 Author: Klesh Wong <[email protected]> AuthorDate: Fri Mar 8 16:39:26 2024 +0800 fix: unable to trigger blueprints with webhooks only --- backend/server/services/blueprint.go | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/backend/server/services/blueprint.go b/backend/server/services/blueprint.go index 8e693ab11..2f7ddb51a 100644 --- a/backend/server/services/blueprint.go +++ b/backend/server/services/blueprint.go @@ -320,21 +320,21 @@ func createPipelineByBlueprint(blueprint *models.Blueprint, syncPolicy *models.S newPipeline.SyncPolicy = blueprint.SyncPolicy // if the plan is empty, we should not create the pipeline - var shouldCreatePipeline bool - for _, stage := range plan { - for _, task := range stage { - switch task.Plugin { - case "org", "refdiff", "dora": - default: - if !plan.IsEmpty() { - shouldCreatePipeline = true - } - } - } - } - if !shouldCreatePipeline { - return nil, ErrEmptyPlan - } + // var shouldCreatePipeline bool + // for _, stage := range plan { + // for _, task := range stage { + // switch task.Plugin { + // case "org", "refdiff", "dora": + // default: + // if !plan.IsEmpty() { + // shouldCreatePipeline = true + // } + // } + // } + // } + // if !shouldCreatePipeline { + // return nil, ErrEmptyPlan + // } pipeline, err := CreatePipeline(&newPipeline, false) // Return all created tasks to the User if err != nil {
