Open jbuckmccready opened 1 year ago
Seems we are running into the same issue here. When running from the IDE, project.assets.json
is generated with all dependencies present and everything builds. When running from the command line, dependencies are missing and the project will fail with missing reference errors.
This project targets net8-windows, uses WPF and ReactiveUI.
Description
For a windows WPF project changing the target OS version to 10.0.x breaks the restoration process when building using
msbuild
ordotnet build
but I am able to build from Visual Studio 2022 UI. Using only Nuget (no paket) this problem does not occur, everything gets restored and builds properly even when targeting OS version 10.0.x.Repro steps
Please provide the steps required to reproduce the problem
dotnet paket install
).Build
, the packages are restored and build works as expected. Rundotnet build
or use themsbuild.exe
tool and the restore process produces aproject.assets.json
file in theobj
directory which is missing all the dependencies and the build fails due to missing types/namespaces from dependencies.I attached a zip file of a minimal project which has the problem: package_restore_silently_fails.zip
I found this issue because the latest version of ReactiveUI only has
net6.0-windows10.0.17763
andnet7.0-windows10.0.17763
listed under its frameworks. So when I try to build with earlier target OS version it gives a warning about falling back to using the version which targets .NET framework. See related issue here: https://github.com/reactiveui/ReactiveUI/issues/3471