Skip to content

plan-preview returns "no updated applications" when trigger.onCommit.disabled is true #6722

@seipan

Description

@seipan

In our setup every app has trigger.onCommit.disabled: true.

The side effect is that pipectl plan-preview (and the actions-plan-preview GitHub Action) always returns "no updated applications" for us. We lose the PR diff preview entirely, even though that's
exactly what we'd want during code review.

The gate is here:

// pkg/app/piped/trigger/determiner.go
func (d *OnCommitDeterminer) ShouldTrigger(...) (bool, error) {
    if appCfg.Trigger.OnCommit.Disabled {
        return false, nil
    }
    ...
}

builder.findTriggerApps uses the same determiner, so apps with onCommit.disabled: true are filtered out before any diff is computed.

Would it be possible to add a flag like --skip-trigger-check to pipectl plan-preview (and a corresponding input on actions-plan-preview) that bypasses this gate? plan-preview is a read-only operation, so
opting in per-invocation feels safer than changing the app config. Default would stay as today.

Happy to send a PR if the direction sounds good.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions