Commit 4256aed
authored
Populate unproxied targets to avoid dropping requested targets (dotnet#9130)
Fixes dotnet#9117
For project cache plugins to only partially handle a build request, it makes sense for it to only proxy some targets and not others. For example, in VS the build request has:
"Build"
"BuiltProjectOutputGroup"
"BuiltProjectOutputGroupDependencies"
"DebugSymbolsProjectOutputGroup"
"DebugSymbolsProjectOutputGroupDependencies"
"DocumentationProjectOutputGroup"
"DocumentationProjectOutputGroupDependencies"
"SatelliteDllsProjectOutputGroup"
"SatelliteDllsProjectOutputGroupDependencies"
"SGenFilesOutputGroup"
"SGenFilesOutputGroupDependencies"
"Build" is the only relevant one that a plugin would want to handle, and would likely redirect to "GetTargetPath", while the rest are "information gathering" targets which should just be "passed through" and allowed to execute as-is.
Today if the plugin does this, the targets it does not proxy are dropped entire, which would make the caller confused about not getting results for a target they specifically requested. This change instead just fills in the remaining targets which were not proxied.
Example:
Original request: Build, BuiltProjectOutputGroup, BuiltProjectOutputGroupDependencies, ...
Cache plugin returns proxy targets Build -> GetTargetPath, and nothing more.
New request: GetTargetPath, BuiltProjectOutputGroup, BuiltProjectOutputGroupDependencies, ...
This fixes dotnet#9117 indirectly by not requiring a plugin to handle targets it wants to pass through at all, allowing it to just ignore them.1 parent 2016d60 commit 4256aed
File tree
6 files changed
+109
-36
lines changed- src
- Build.UnitTests
- BackEnd
- ProjectCache
- Build/BackEnd
- BuildManager
- Components/ProjectCache
6 files changed
+109
-36
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| 15 | + | |
14 | 16 | | |
15 | 17 | | |
16 | 18 | | |
| |||
19 | 21 | | |
20 | 22 | | |
21 | 23 | | |
22 | | - | |
23 | | - | |
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| |||
544 | 544 | | |
545 | 545 | | |
546 | 546 | | |
547 | | - | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
548 | 554 | | |
549 | 555 | | |
550 | 556 | | |
| |||
806 | 812 | | |
807 | 813 | | |
808 | 814 | | |
809 | | - | |
810 | | - | |
811 | 815 | | |
812 | 816 | | |
813 | 817 | | |
| |||
816 | 820 | | |
817 | 821 | | |
818 | 822 | | |
819 | | - | |
| 823 | + | |
820 | 824 | | |
| 825 | + | |
821 | 826 | | |
822 | 827 | | |
823 | 828 | | |
824 | 829 | | |
825 | | - | |
826 | | - | |
827 | | - | |
828 | | - | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
829 | 833 | | |
830 | 834 | | |
831 | | - | |
832 | 835 | | |
833 | 836 | | |
834 | 837 | | |
835 | 838 | | |
836 | | - | |
837 | | - | |
838 | | - | |
839 | | - | |
840 | | - | |
841 | | - | |
842 | | - | |
843 | | - | |
844 | | - | |
845 | | - | |
846 | | - | |
847 | | - | |
848 | | - | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
849 | 843 | | |
850 | 844 | | |
851 | 845 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
507 | 507 | | |
508 | 508 | | |
509 | 509 | | |
510 | | - | |
511 | 510 | | |
512 | 511 | | |
513 | 512 | | |
| |||
766 | 765 | | |
767 | 766 | | |
768 | 767 | | |
| 768 | + | |
| 769 | + | |
| 770 | + | |
| 771 | + | |
| 772 | + | |
| 773 | + | |
| 774 | + | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
| 779 | + | |
| 780 | + | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
769 | 821 | | |
770 | 822 | | |
771 | 823 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1783 | 1783 | | |
1784 | 1784 | | |
1785 | 1785 | | |
1786 | | - | |
| 1786 | + | |
1787 | 1787 | | |
1788 | 1788 | | |
1789 | 1789 | | |
| 1790 | + | |
| 1791 | + | |
| 1792 | + | |
| 1793 | + | |
| 1794 | + | |
| 1795 | + | |
| 1796 | + | |
| 1797 | + | |
| 1798 | + | |
| 1799 | + | |
| 1800 | + | |
| 1801 | + | |
| 1802 | + | |
| 1803 | + | |
1790 | 1804 | | |
1791 | 1805 | | |
1792 | 1806 | | |
1793 | | - | |
| 1807 | + | |
1794 | 1808 | | |
| 1809 | + | |
1795 | 1810 | | |
1796 | 1811 | | |
1797 | 1812 | | |
| |||
2294 | 2309 | | |
2295 | 2310 | | |
2296 | 2311 | | |
2297 | | - | |
| 2312 | + | |
2298 | 2313 | | |
2299 | 2314 | | |
2300 | 2315 | | |
| |||
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
30 | 47 | | |
31 | 48 | | |
32 | 49 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
128 | 128 | | |
129 | 129 | | |
130 | 130 | | |
| 131 | + | |
131 | 132 | | |
132 | 133 | | |
133 | 134 | | |
| |||
137 | 138 | | |
138 | 139 | | |
139 | 140 | | |
| 141 | + | |
140 | 142 | | |
141 | 143 | | |
142 | 144 | | |
143 | 145 | | |
144 | 146 | | |
145 | 147 | | |
146 | 148 | | |
147 | | - | |
| 149 | + | |
148 | 150 | | |
149 | 151 | | |
150 | 152 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
745 | 745 | | |
746 | 746 | | |
747 | 747 | | |
748 | | - | |
749 | | - | |
750 | | - | |
751 | | - | |
752 | | - | |
753 | | - | |
754 | | - | |
755 | 748 | | |
756 | 749 | | |
757 | 750 | | |
| |||
0 commit comments