I\'m trying to publish a WPF Application (to a folder) targeting .NET Core 3.1, using Publish Single File, targeting win-x86. The application publishes fine for Debug, but fails
For me the error has to do with custom nuget sources, like Azure DevOps Artifacts. Sometimes the build script tries to restore nugets from Azure DevOps and fails with a (Unauthorized) error, which produces the error in the post.
Temporarily disabling the custom nuget sources, makes publish work again regardless of the options used like single file.