-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
deps file is not regenerated when non-nuget references change #1942
Comments
Is this something that we should/can address for 2.1? I ask so that I can figure out which milestone to put this at. Also, where is the code for this? I saw the GenerateDepsFilei is set to true for core or for PreserverCompilationContext == true. Is this in the task? |
Code is here: sdk/src/Tasks/Microsoft.NET.Build.Tasks/build/Microsoft.NET.Sdk.targets Lines 121 to 122 in 9f97fce
This only input is the assets file. As far as milestone, since I found this by code inspection, and haven't seen a report yet, it can maybe wait until after 2.1.3xx. |
I missed the inputs, only looked at condition. All right. Marking for a future release then. |
Cheap fix is adding MSBuildAllProjects to inputs. It isn't perfect, but many other targets use the same approximation for incrementality. We should maybe just do that. Otherwise, need to do fancier tricks like CoreCompile and GenerateAssemblyInfo do. |
I like simple fixes. |
Do you gather anything more than just TargetPath from project references? (EG: copy local content, or binaries referenced by a ProjectReference) If so, that complicates things since those wouldn't be covered by MSBuildAllProjects of this project. If not then its probably OK. |
@tannergooding is looking at gathering the reference dependencies. |
I will likely include the simple fix for this (add |
Fixes dotnet#1942 (in most cases)
Fixes dotnet#1942 (in most cases)
Fixes dotnet#1942 (in most cases)
Fixes dotnet#1942 (in most cases)
Fixes dotnet#1942 (in most cases)
Fixes dotnet#1942 (in most cases)
Currently the target that generates the deps file only runs when project.assets.json is older than deps.json, but if non-package references are changed, then the deps file would also need to change.
We do want to keep incrementality because it is an expensive operation, but we should account for the other task parameters that can change the deps file.
The text was updated successfully, but these errors were encountered: