Open VaclavElias opened 2 months ago
I did a few more tests for code only simple project.
Even though there is no mentioned package system.security.cryptography.pkcs
6.0.0
I guess, something changed in our configurations in the last 2 releases, as previously, I didn't need to do this.
When I add this to the code only project <RuntimeIdentifier>win-x64</RuntimeIdentifier>
all references are resolved including the package System.Security.Cryptography.Pkcs
.
Fixed with https://github.com/stride3d/stride-community-toolkit/pull/134.
Some notes from Discord:
I was able to debug the error but I wasn't able to find the issue itself because it happens in the NuGet library itself. I moved on and these are the suggetions for the toolkit for now:
Anywhere we reference Stride.Core.Assets.CompilerApp
we have to add also <RuntimeIdentifier>win-x64</RuntimeIdentifier>
which makes it Windows only.
Stride.CommunityToolkit
library will have no Stride.Core.Assets.CompilerApp
references, so it can be built correctly and be platfom agnostic. Should work in code-only and regular Stride Projects.Stride.CommunityToolkit.Windows
library will have Stride.Core.Assets.CompilerApp
reference and also <RuntimeIdentifier>win-x64</RuntimeIdentifier>
, at the moment it is an empty library refrencing Stride.CommunityToolkit
project mainly for code-only purpose, just to remove the above boilerplate. That means, code only examples would reference Stride.CommunityToolkit.Windows
instead of Stride.CommunityToolkit
. This could be done also for Linux later.Stride.CommunityToolkit.Skyboxes
library mainly for code-only purpose, will have Stride.Core.Assets.CompilerApp
reference removed so the NuGet package can be created. Because it is used with Stride.CommunityToolkit.Windows
, it should build correctlyThis shouldn't be necessary anymore with #2279.
Looking forward to test it 🙂
Running into the same issue over here. It's easily reproducible after deleting the .nuget folder in your user folder. After that a command line build of a Stride based project fails.
Basically the assembly resolver installed by Stride.NugetResolver onto the Stride.Core.Assets.CompilerApp leads to a package restore which might start downloading packages and in turn verifying them. That verify call can be seen in the above posted callstack. It tries to load System.Security.Cryptography.Pkcs.dll
which is not present in the exe folder (.nuget\packages\stride.core.assets.compilerapp\4.2.0.2121\lib\net8.0
in my case). After copying that file to that location manually the compiler app ran successfully.
How can we make sure that file (System.Security.Cryptography.Pkcs.dll
) is bundled with the nuget package?
My issue was related to the toolkit and code-only. What was your scenario?
We use Stride in vvvv. Users can export applications which lead to kind of code-only projects.
I see! So you came across this issue independently, which is great because I though it is a toolkit related. Thanks. I wasn't able to fix it myself.
Had to revert the fix mentioned above, see #2317
Release Type: Official Release
Version: 4.2.0.2122
Platform(s): Windows
Describe the bug Build fails for code only simple projects.
Similar issue https://github.com/stride3d/stride/issues/1279
To Reproduce Steps to reproduce the behavior: https://github.com/stride3d/stride-community-toolkit/issues/133
Expected behavior The build was working previously with 4.2.0.2067
Screenshots N/a
Log and callstacks
Additional context Add any other context about the problem here.