You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Orleans I just discovered a weird issue: in the nuspec the project references for our Release packages pointed to 1.5.0-dev instead of 1.5.0. We're using only suffixes for Debug builds.
It turned out that since we only did a package restore (like in the old days) at the beginning of the build once, project.assets.json got the version suffix burned in, since the first build was Debug.
Because of this an invalid package reference was generated for the projects.
If the project.assets.json would go under obj\Debug together with the generated props and targets file this situation would not happen.
Portion of our Directory.Build.props file:
<!-- For Debug builds generated a date/time dependent version suffix -->
<PropertyGroup Condition=" '$(Configuration)'=='Debug' ">
<VersionSuffix Condition=" '$(VersionSuffix)'=='' ">dev</VersionSuffix>
<VersionSuffix Condition=" '$(VersionDateSuffix)'!='' ">$(VersionSuffix)-$(VersionDateSuffix)</VersionSuffix>
</PropertyGroup>
The text was updated successfully, but these errors were encountered:
attilah
changed the title
project.assets.json should be under Configuration folder within intermediate path
project.assets.json should be under Configuration specific folder within intermediate path
May 30, 2017
Before 2.0, doing a dotnet restore would overwrite existing project.assets.json. In 2.0, you need to pass in -f to force rewriting of the file.
In our case, we also need to have the file placed under a directory with target framework. I think it should follow how other generated files are placed: /obj/<configuration>/<target framework>/project.assets.json.
@sstevenkang looking at dotnet/cli#7686, you are facing this problem because you have 2 different csproj files in the same folder, which is unsupported.
But you can workaround this by adding a --Force to the restore calls which will result in rewriting of the assets file each time.
In Orleans I just discovered a weird issue: in the nuspec the project references for our Release packages pointed to 1.5.0-dev instead of 1.5.0. We're using only suffixes for Debug builds.
It turned out that since we only did a package restore (like in the old days) at the beginning of the build once, project.assets.json got the version suffix burned in, since the first build was Debug.
Because of this an invalid package reference was generated for the projects.
If the project.assets.json would go under obj\Debug together with the generated props and targets file this situation would not happen.
Portion of our Directory.Build.props file:
The text was updated successfully, but these errors were encountered: