[hidi] `hidi transform` can't be cancelled or aborted. Process needs to be killed manually.
Steps to replicate
From the PowerShell command line, running the following command:
hidi transform -cs "https://graph.microsoft.com/v1.0/`$metadata" -f Yaml -o .\microsoft-graph.yaml -co
Microsoft.OpenAPI.Hidi.exe starts and consumes 25% CPU and memory usage starts increasing over 2GB. Tried to CTRL-C from the command line which would normally terminate the process. Memory usage continued climbing to ~6GB without completing.
Expected behavior
CTRL-C should abort the transformation process immediately or within a few seconds. Manually killing the Microsoft.OpenAPI.Hidi process should not be required.
Tool version
Package: microsoft.openapi.hidi
Version: 1.0.0-preview4
dotnet --info
❯ dotnet --info
.NET SDK (reflecting any global.json):
Version: 6.0.300
Commit: 8473146e7d
Runtime Environment:
OS Name: Windows
OS Version: 10.0.22000
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\6.0.300\
Host (useful for support):
Version: 6.0.5
Commit: 70ae3df4a6
.NET SDKs installed:
3.1.419 [C:\Program Files\dotnet\sdk]
5.0.214 [C:\Program Files\dotnet\sdk]
5.0.408 [C:\Program Files\dotnet\sdk]
6.0.300 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 3.1.25 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 3.1.25 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.25 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 5.0.17 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
To install additional .NET runtimes or SDKs:
https://aka.ms/dotnet-download
You will struggle to process the complete public metadata on Graph because there are a number of containment annotations that are lies for legacy reasons. Unfortunately the lies cause the size of the OpenAPI description to become massive. We have an XSLT that "fixes" the lies before processing for SDK generation. This is one reason that we publish our pre-generated OpenAPI description in the https://github.com/microsoftgraph/msgraph-metadata repo.
Thanks for the workaround! Let's make sure that we still can "cancel" or "abort" any CLI commands we do. 😄