Maybe try adding, "DOTNET_UPGRADEASSISTANT_TELEMETRY_OPTOUT" environment variable to "1"?
Ref - https://learn.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-telemetry?tabs=console#disclosure On Wed, 13 Sept 2023 at 16:55, [email protected] <[email protected]> wrote: > Hi team, > > I am trying to run Microsoft upgrade assistant but its failing with below > error > Same command i am running through command prompt, it works as expected. > > i am running that it in non-interative mode so that microsoft upgrade > assistant doesn't wait for user input on console. however running with GOCD > task it still wait for user input and failing > > can you please help me with that > > > [go] Task: cmd /c "upgrade-assistant.exe upgrade > D:\Upgrade\GOPIPE\WEBAPP\SampleAPI\SampleEfAPI.csproj --operation Inplace > --targetFramework net6.0 --non-interactive" > > Initializing and loading extensions... > Telemetry > Upgrade Assistant collects usage data in order to help us improve your > experience. The data is collected by Microsoft and shared with the > community. > You can opt-out of telemetry by setting the > DOTNET_UPGRADEASSISTANT_TELEMETRY_OPTOUT environment variable to '1' or > 'true' > using your favorite shell. > Read more about Upgrade Assistant telemetry: > https://aka.ms/upgrade-assistant-telemetry > Read more about .NET CLI Tools telemetry: > https://aka.ms/dotnet-cli-telemetry > Press any key to continue... > System.InvalidOperationException: Cannot read keys when either application > does > not have a console or when console input has been redirected. Try > Console.Read. > at System.ConsolePal.ReadKey(Boolean intercept) > at > > Microsoft.UpgradeAssistant.Cli.Startup.FirstUseStartup.StartupAsync(Cancellation > Token cancellationToken) in > > D:\a\_work\1\s\src\Experiments\UpgradeAssistant\cli\Startup\FirstUseStartup.cs:l > ine 37 > at > > Microsoft.UpgradeAssistant.Cli.Flow.Steps.Upgrade.StartupFlowStep.ValidateUserIn > putAsync(IFlowContext context, CancellationToken cancellationToken) in > > D:\a\_work\1\s\src\Experiments\UpgradeAssistant\cli\Flow\Steps\Startup\StartupFl > owStep .cs:line 34 > at Spectre.Console.Flow.FlowRunner.RunAsync(CancellationToken > cancellationToken) in > > D:\a\_work\1\s\src\Experiments\UpgradeAssistant\spectre.flow\Flow\FlowRunner.cs: > line 83 > > -- > You received this message because you are subscribed to the Google Groups > "go-cd" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/go-cd/007cd4c6-639a-430f-bf49-53d6649b22d5n%40googlegroups.com > <https://groups.google.com/d/msgid/go-cd/007cd4c6-639a-430f-bf49-53d6649b22d5n%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Ashwanth Kumar / ashwanthkumar.in -- You received this message because you are subscribed to the Google Groups "go-cd" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/go-cd/CAD9m7CyUa7YbuSBB4gNjytKd%2BxccqXJy5cHVRMf2RUqJ9gv47Q%40mail.gmail.com.
