]> Cypherpunks repositories - gostls13.git/commit
cmd/go/internal/modload: replace import error message from goroot to std
authorjchen038 <mfwinds@gmail.com>
Tue, 29 Nov 2022 08:05:54 +0000 (00:05 -0800)
committerGopher Robot <gobot@golang.org>
Mon, 15 May 2023 16:24:01 +0000 (16:24 +0000)
commit1b896bff30c7622e6d26a1fd30a73d964a860481
tree9c3f18d62c0b1a39a2215ad98fa82e5dbd1506f5
parent0e7a2504224716fd233c07b7d19ed9fe317caa9c
cmd/go/internal/modload: replace import error message from goroot to std

When importing a package that does not exist, it would show goroot error
message and path. We would like to replace goroot with std instead.

Fixes #56965.

Change-Id: I86f8a7fab6555b68f792a3a4686de20d51eced8b
Reviewed-on: https://go-review.googlesource.com/c/go/+/453895
Run-TryBot: Bryan Mills <bcmills@google.com>
Auto-Submit: Bryan Mills <bcmills@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
src/cmd/go/internal/modload/import.go
src/cmd/go/testdata/script/cmd_import_error.txt
src/cmd/go/testdata/script/mod_get_replaced.txt
src/cmd/go/testdata/script/mod_goroot_errors.txt
src/cmd/go/testdata/script/mod_issue35270.txt
src/cmd/go/testdata/script/mod_load_missing_std.txt
src/cmd/go/testdata/script/mod_tidy_error.txt
src/cmd/go/testdata/script/mod_vendor.txt
src/go/build/build_test.go