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.
[internal] Simplify config parsing. (pantsbuild#14846)
There were too many unnecessary abstractions bogging down the code, and making it harder to adapt and modify. This change streamlines things by getting rid of the Single/Chained config classes. Instead the _ConfigValues class, which already did most of the work, takes a new path field, so it can encapsulate the source file from which its values were parsed. Then, the Config ABC becomes a regular concrete dataclass that exists to directly handle multiple config files. This allows us to remove many superfluous methods, exceptions and logic, that were only there to prop up the abstractions. [ci skip-rust] [ci skip-build-wheels]
- Loading branch information
Showing
7 changed files
with
85 additions
and
325 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
Oops, something went wrong.