You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I try to run dotnet build or dotnet restore in Docker, then the process crashes. Sometimes it even hangs, tying up the user's shell session.
Trace
$ docker run --rm -it hello dotnet restoreWelcome to .NET 8.0!---------------------SDK Version: 8.0.401----------------Installed an ASP.NET Core HTTPS development certificate.To trust the certificate, view the instructions: https://aka.ms/dotnet-https-linux----------------Write your first app: https://aka.ms/dotnet-hello-worldFind out what's new: https://aka.ms/dotnet-whats-newExplore documentation: https://aka.ms/dotnet-docsReport issues and find source on GitHub: https://github.com/dotnet/coreUse 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli--------------------------------------------------------------------------------------Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object. at Regex1_Scan(RegexRunner, ReadOnlySpan`1)
Bad process state
Several problems are happening.
dotnet restore triggers a null pointer error, instead of generating a security report for Npgsql.
When dotnet restore runs inside a docker run --rm -it hello bash REPL session, then it triggers a null pointer error and crashes back to the container shell prompt (#).
However, when dotnet restore runs as a one-off command with docker run --rm -it hello dotnet restore, then the same null pointer error shows but the process hangs, failing to terminate the process and return control back to the host shell (e.g. $ on macOS).
For comparison, dotnet restore appears to work fine when run directly on the host (at least for macOS and Windows hosts). And a dozen other programming languages work just fine in Fedora (v41) in Docker (v27). .NET is the first one I've seen segfault with a Hello World project since Swift and Z*g.
As an aside, installing nuget via DNF and running nuget results in SIGABRT crashes. Something's rotten in the state of .NET.
usingNpgsql;Console.WriteLine("Hello World!");Console.WriteLine($"Database connector: {ServerCompatibilityMode.Redshift}");//// Example privacy violation.// A social security number leaks through application logs.//Console.Write("SSN: ");varssn=Console.ReadLine();// Console.WriteLine("Registered user.");Console.WriteLine($"Registered user. SSN: {ssn}");
The text was updated successfully, but these errors were encountered:
aep-sunlife
changed the title
dotnet restore crashesdotnet restore crashing/hanging
Dec 13, 2024
Hi,
When I try to run
dotnet build
ordotnet restore
in Docker, then the process crashes. Sometimes it even hangs, tying up the user's shell session.Trace
Bad process state
Several problems are happening.
dotnet restore
triggers a null pointer error, instead of generating a security report for Npgsql.When
dotnet restore
runs inside adocker run --rm -it hello bash
REPL session, then it triggers a null pointer error and crashes back to the container shell prompt (#
).However, when
dotnet restore
runs as a one-off command withdocker run --rm -it hello dotnet restore
, then the same null pointer error shows but the process hangs, failing to terminate the process and return control back to the host shell (e.g.$
on macOS).For comparison,
dotnet restore
appears to work fine when run directly on the host (at least for macOS and Windows hosts). And a dozen other programming languages work just fine in Fedora (v41) in Docker (v27). .NET is the first one I've seen segfault with a Hello World project since Swift and Z*g.As an aside, installing
nuget
via DNF and runningnuget
results in SIGABRT crashes. Something's rotten in the state of .NET.Dockerfile
hello.csproj
Hello.cs
The text was updated successfully, but these errors were encountered: