Skip to content
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

Hololens Build Errors #13

Closed
saratrajput opened this issue Feb 9, 2022 · 5 comments
Closed

Hololens Build Errors #13

saratrajput opened this issue Feb 9, 2022 · 5 comments

Comments

@saratrajput
Copy link
Contributor

Hello, I'm following the Youtube guide to build the app for Hololens. I run into the following error:

InvalidOperationException: Certificate Assets/WSATestCertificate.pfx is expired and cannot be used for a UWP build. To fix this, either delete it or select a different certificate in the player settings.
PostProcessWinRT.CreateTestCertificate () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessWinRT.cs:1071)
PostProcessWinRT.Process () (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/PostProcessWinRT.cs:173)
UnityEditor.UWP.BuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:85)
Rethrow as BuildFailedException: Exception of type 'UnityEditor.Build.BuildFailedException' was thrown.
UnityEditor.UWP.BuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args) (at C:/buildslave/unity/build/PlatformDependent/MetroPlayer/Extensions/Managed/ExtensionModule.cs:89)
UnityEditor.Modules.DefaultBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at <8004fcc221b54f98ba547350ea71d812>:0)
UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <8004fcc221b54f98ba547350ea71d812>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
@saratrajput
Copy link
Contributor Author

A quick solution would be to create a new certificate from Project Settings -> Player -> Publishing Settings -> Create (under Expiration date)
image

Delete any old builds and build again.

@EricVoll
Copy link
Contributor

EricVoll commented Feb 9, 2022

Hi @saratrajput
Thanks for raising this issue. I'll have a look at it asap

@saratrajput
Copy link
Contributor Author

Also, I forgot to mention one more thing. When you create the new certificate, leave the password section empty. Visual Studio might not be able to open the certificate otherwise.

@EricVoll
Copy link
Contributor

I'll create a PR in a second with these changes. Thanks.

@EricVoll
Copy link
Contributor

I'll close this issue for now, since I expect the issue to be solved on the latest master. If it still persists, please fell free to reopen it again.
-Eric

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants