-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Fix Plugin Resolution #3858
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
Fix Plugin Resolution #3858
Conversation
The diff of the |
Thanks a bunch for taking the time to split this out @SDGGiesbrecht! This looks good to me. |
@swift-ci please smoke test |
Note: We'll probably see some async-related failures in the Linux self hosted test due to unrelated reasons. Should clear up with a later toolchain, but shouldn't hold up merging this if everything else passes. |
@swift-ci please smoke test |
Is that what #3865 is about? |
yes |
@swift-ci please smoke test linux |
I did some extra testing on this, and it seems to work great, also in a client of libSwiftPM. Thanks @SDGGiesbrecht. |
Spun out of #3838. This contains only the pieces related to fixing plugins, which contained bugs affecting both resolution modes.
I added two tests that are independent of the resolution mode, one to make sure plugin executables are usable even when they are not attached to any product (which was the primary thing broken), and the other to make sure that such executables are not accessible outside of the plugin itself.
To make the second test work even with legacy full resolution, I needed to explicitly block synthesized products from dependency links (in
PackageGraph+Loading.swift
). That should also make it more resilient during hypothetical future refactors, because it does not rely on the order of the loading process.@abertelrud