After working with PCF during the initial private preview, I haven’t had a chance to use it in anger. Until today. And it didn’t go smoothly.
It started well. I installed the CLI tooling, got a new template control ready to go with
pac pcf init and connected to CDS with
pac auth create. Next I tried to publish the control with
pac pcf push when it failed.
The build log indicated a
401 Unauthorized error with an internal NuGet feed.
For context, I mostly do C# development using Azure DevOps to store internal NuGet packages. I use this every day in Visual Studio without problems. In this case though, I’m don’t even need to use a package from that feed, but something’s trying to connect to it anyway.
If I remove the internal feed from the list in
NuGet.config, it works fine. But this breaks my work in Visual Studio, so that’s not really an option.
So I went back to basics and followed through the process of connecting to the Azure DevOps feed. The first step was to install the tooling, but that was already installed. The next was to run
dotnet restore --interactive. Doing this from the folder containing my PCF project prompted me to enter an MFA code, then proceeded successfully.
After this my
pac pcf push commands worked correctly! A frustrating way to spend an hour or so today, but hopefully this will help someone out.