Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/go: module loader fails to resolve imports within symlinked source file [1.12 backport] #31763

gopherbot opened this issue Apr 30, 2019 · 2 comments


Copy link

@gopherbot gopherbot commented Apr 30, 2019

@katiehockman requested issue #28107 to be considered for backport to the next 1.12 minor release.

@gopherbot please open a backport to 1.12. This is a low risk patch that has enough benefits to warrant a cherrypick.


This comment has been minimized.

Copy link

@gopherbot gopherbot commented May 6, 2019

Change mentions this issue: [release-branch.go1.12] cmd/go/internal/imports: use the full path to resolve symlinks


This comment has been minimized.

Copy link

@gopherbot gopherbot commented May 6, 2019

Closed by merging 4a1d39b to release-branch.go1.12.

@gopherbot gopherbot closed this May 6, 2019
gopherbot pushed a commit that referenced this issue May 6, 2019
… resolve symlinks

info.Name returns a name relative to the directory, so we need to
prefix that directory in the Stat call.

(This was missed in CL 141097 due to the fact that the test only
happened to check symlinks in the current directory.)

This allows the misc/ tests to work in module mode on platforms that
support symlinks.

Updates #30228
Updates #28107
Fixes #31763

Change-Id: Ie31836382df0cbd7d203b7a8b637c4743d68b6f3
Run-TryBot: Bryan C. Mills <>
TryBot-Result: Gobot Gobot <>
Reviewed-by: Jay Conrod <>
Reviewed-by: Andrew Bonventre <>
Reviewed-by: Brad Fitzpatrick <>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.