Skip to content

Go: don't set GOTOOLCHAIN=local #202030

@andig

Description

@andig

brew gist-logs <formula> link OR brew config AND brew doctor output

❯ brew doctor
Your system is ready to brew.

Verification

  • My brew doctor output says Your system is ready to brew. and am still able to reproduce my issue.
  • I ran brew update and am still able to reproduce my issue.
  • I have resolved all warnings from brew doctor and that did not fix my problem.
  • I searched for recent similar issues at https://github.com/Homebrew/homebrew-core/issues?q=is%3Aissue and found no duplicates.

What were you trying to do (and why)?

Coming from golang/go#70949 where Go fails to install newer toolchain for compiling module. This is due to https://github.com/Homebrew/homebrew-core/blob/master/Formula/g/go.rb#L93. While this may be the right setting for compiling brew formulas, it breaks using Go for other purposes.

What happened (include all command output)?

go build

go: errors parsing go.mod:
go.mod:206: unknown block type: tool

What did you expect to happen?

Go 1.23 downloads Go 1.24 and compiles successfully.

Step-by-step reproduction instructions (by running brew commands)

n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugReproducible Homebrew/homebrew-core bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions