forked from pantsbuild/pants
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use
go list
to analyze stdlib imports (pantsbuild#12368)
## Problem As described in pantsbuild#11910, the current version of the experimental Go plugin parses the directory structure of the Go distribution to determine the imports provided by the standard library. `go list` already provides this information in JSON form when asked. This was also how the v1 plugin obtained the same information. ## Solution Use `go list` to obtain import paths for the standard library. This PR introduces the base class `ResolvedImportPaths` which will be inherited by all types that represent import path mappings. The first use of this base class is for the `ResolvedImportPathsForGoLangDistribution` dataclass which represents analysis of the Go standard library. ## Testing Added integration test for the import analysis and the first-party build integration test continues to pass. Closes pantsbuild#11910. [ci skip-rust]
- Loading branch information
Tom Dyas
authored
Jul 17, 2021
1 parent
532d5ff
commit 40469dc
Showing
7 changed files
with
241 additions
and
161 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.