dotnet / dotnet/arcade

NuGet Validation fails when a pipeline doesn't produce any nuget packages

Open
#14,594 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
729
Forks
397
Avg merge
3d 15m
Merged PRs (30d)
149

Description

- [x] This issue is blocking
- [ ] This issue is causing unreasonable pain

We have a repo that needs to disable packages occasionally. When it does so there is no way for the pipeline to disable the `NuGet Validation`. It fails because it attempts to download

The only way to disable this step is through the `enableNugetValidation` pipeline parameter. AFAICT we cannot set this dynamically based on the source in the repo, so developers would need to "remember" to enable and disable this parameter.

Ideally this step should automatically skip if there are no packages to publish. I tried to do this but couldn't get the yml authoring correct. My non-working attempt is here: https://dev.azure.com/dnceng/internal/_git/dotnet-maintenance-packages/commit/aa4716ed8a6a16b11e9680e26a5b134a46a2386f?refName=refs%2Fheads%2FconditionPackageValidation
I couldn't get the plumbing of the variable correct (and it also needs to be set in the true case).

It would be best if arcade would support this.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.