-
-
Notifications
You must be signed in to change notification settings - Fork 636
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
Significantly reduce the dependencies of RuleRunner
#15631
Significantly reduce the dependencies of RuleRunner
#15631
Conversation
While this could potentially be a candidate for #13393, the exact rule that we would use here isn't clear to me. |
[ci skip-rust]
1477db9
to
6b30592
Compare
@@ -111,6 +111,7 @@ def load_build_configuration_from_source( | |||
:raises: :class:``pants.base.exceptions.BuildConfigurationError`` if there is a problem loading | |||
the build configuration. | |||
""" | |||
# NB: Backends added here must be explicit dependencies of this module. | |||
backend_packages = FrozenOrderedSet(["pants.core", "pants.backend.project_info", *backends]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would string import inference work here? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not out of the box I don't think... the actual underlying modules are pants.core.register
and pants.backend.project_info.register
.
The entire
init
package depended on theplugins
target, but the underlying reason for that dependency was to include all plugins in published distributions and PEXes... which are defined in thebin
package. As a side-effect, allRuleRunner
tests depended on all plugins, which significantly increased the size of their cache keys.Before:
After:
Moral of the story: explicit deps are dangerous...?
[ci skip-rust]