Skip to content

Every build uses .NET 10.0.13 or later, so TuiCode no longer crashes on macOS when a Go program starts it #563

Open

Description

@a-team-app

Context

On macOS, a TuiCode build on .NET 10.0.12 crashes at random when a Go program started it (lazygit or gh opening it as $EDITOR, tuirec recording it): an upstream Native AOT bug, fixed in .NET 10.0.13. Nothing ties a build to a fixed SDK today, so this task pins every build, local and CI, to SDK 10.0.402 or later. See the pitch, #509, for the diagnosis and the decisions.

Before you start: dotnet --list-sdks must show 10.0.402 or a newer 10.0 SDK. The stakeholder installs it; if it's missing, hand the task back as blocked rather than working around it.

Acceptance criteria

  • On a Mac with SDK 10.0.402 or later, building and running TuiCode works as before.
  • On a machine whose newest 10.0 SDK is older than 10.0.402 (e.g. 10.0.401), a build stops with .NET's "SDK not found" message naming 10.0.402, instead of building with the old compiler.
  • A .NET 11 preview SDK being installed doesn't satisfy it: the build still asks for 10.0.402.
  • CI and the Release workflow build with the SDK the repo asks for, and the macOS AOT build resolves ILCompiler 10.0.13 or later (stated in the PR, with the line from the job log or project.assets.json).
  • A macOS Native AOT build of this branch, launched by tuirec, survives the 200-GC repro from the pitch's original report (or the same session that crashed before). The PR says what was run and what it printed.
  • The contributor docs say which SDK to install to build TuiCode.
  • The PR title reads as a release note a macOS user would act on, since --generate-notes uses it: e.g. Fix random crashes on macOS when started from lazygit, gh or another Go tool.

Tests

  • No new automated test for the crash itself: it would test .NET's fix, and needs a C shim on the macOS runner (out of scope in the pitch).
  • Existing tests and the CI aot job pass on every platform with the new SDK.
  • Check by hand, and say in the PR, that a build with only an older 10.0 SDK visible fails as described.

Out of scope

  • Retargeting to .NET 11.
  • Any workaround in TuiCode's own code (signal handling, a launcher script).
  • A PackageReference to Microsoft.DotNet.ILCompiler.
  • Changes in TuiCodeDemos (its intro/run.sh wrapper stays until the stakeholder drops it).
  • Cutting a release.

Activity

  1. a-team-app commented on Oct 14, 2026

    @a-team-app
    ContributorAuthor

    Blocked until SDK 10.0.402 is installed where agent runs can see it.

    • Not installed yet: the newest 10.0 SDK here is 10.0.401.
    • In agent runs, dotnet is Homebrew's (/opt/homebrew/bin comes before /usr/local/share/dotnet on PATH), and it only sees its own SDK, 10.0.105. Homebrew's stable formula is 10.0.401, still unfixed. So installing 10.0.402 into /usr/local/share/dotnet isn't enough on its own. Either also brew unlink dotnet, or brew upgrade dotnet once Homebrew ships 10.0.402.

    Reply here once it's in, and the Dev picks the task up.

  2. jamescrosswell commented on Oct 20, 2026

    @jamescrosswell
    Contributor

    .NET SDK 10.0.402 is installed in /usr/local/share/dotnet

  3. a-team-app commented on Oct 20, 2026

    @a-team-app
    ContributorAuthor

    Thanks. 10.0.402 is in /usr/local/share/dotnet, but which dotnet still gives /opt/homebrew/bin/dotnet first, and that one only sees SDK 10.0.105. So a Dev run would still build with the old one.

    One of these fixes it:

    • brew unlink dotnet (or brew uninstall dotnet), or
    • put /usr/local/share/dotnet before /opt/homebrew/bin on PATH.

    The task isn't labelled blocked, so the Dev can pick it up now. It will hit this if PATH stays as it is.

  4. a-team-app commented on Oct 20, 2026

    @a-team-app
    ContributorAuthor

    Draft PR #584 is up.

  5. added a commit that references this issue on Oct 20, 2026
    c7df4b2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    a-team:devClaimed by the a-team Dev

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions