Skip to content

[feature] Scorecard Certifier: add opt-in for usage of Scorecard API #3013

@gaganhr94

Description

@gaganhr94

Is your feature request related to a problem? Please describe.

Follow-up to PR #2815 (review comment).

Before PR #2815, NewScorecardCertifier acted as a configuration validator: if
GITHUB_AUTH_TOKEN was unset, construction failed loudly at init. PR #2815
changed this to a warning so the API-only path (which doesn't need the token)
can be used without forcing callers to set a token. This is a subtle behavior change for existing callers.

Describe the solution you'd like

Consider restoring fail-fast as the default with an explicit opt-in.
Add a functional option like WithAPIOnly() (or equivalent) that callers
pass when they knowingly want the API-only path. Without the opt-in,
NewScorecardCertifier would return an error when GITHUB_AUTH_TOKEN is
unset, matching the original contract and preserving the config-validation
guarantee that some operators depended on.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions