Closed UkonnRa closed 3 years ago
It looks like you're using the old 0.0.10 binary package that still has a dependency on System.ServiceModel.Web.dll
. The latest 0.0.11 no longer has this dependency. I haven't yet made a 0.0.11 release, but I can make that a higher priority item for me to address.
Well, where could I find the 0.0.11 version? What's more, I want to ask the difference between this plugin and the origin Nuget tool. For I cannot use some packages downloaded from the Nuget tool(yes, I am talking about SocketIoClientDotNet)
I hadn't yet made the 0.0.11 release when I first commented, but it is now available in the releases: https://github.com/GlitchEnzo/NuGetForUnity/releases
As for using the NuGet client built into Visual Studio, that doesn't work because Unity automatically regenerates the .sln and .csproj files whenever any code in the game changes, which wipes away all NuGet packages you've installed. This tool (NuGetForUnity) provides a NuGet client directly inside the Unity Editor that manages all of the NuGet package installation and restoration for you. All packages can be restored even without any .sln or .csproj files.
Additionally, I was able to successfully install SocketIoClientDotNet version 0.9.13 using NuGetForUnity 0.0.11 in Unity 2017.1 on Windows 10.
New question, maybe it is a Mac only problem...
System.Net.WebException: Error: SecureChannelFailure (Security) ---> System.DllNotFoundException: Security
at (wrapper managed-to-native) Mono.AppleTls.AppleTlsContext:SSLCreateContext (intptr,Mono.AppleTls.SslProtocolSide,Mono.AppleTls.SslConnectionType)
at Mono.AppleTls.AppleTlsContext.InitializeConnection () [0x0000c] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.AppleTls.AppleTlsContext.StartHandshake () [0x00015] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.MobileAuthenticatedStream.ProcessHandshake (Mono.Net.Security.AsyncProtocolRequest asyncRequest, Mono.Net.Security.AsyncOperationStatus status) [0x00004] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.AsyncProtocolRequest.ProcessOperation (Mono.Net.Security.AsyncOperationStatus status) [0x0006b] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.AsyncProtocolRequest.ProcessOperation () [0x0000d] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.AsyncProtocolRequest.StartOperation () [0x0003c] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.AsyncProtocolRequest.StartOperation (Mono.Net.Security.AsyncOperation operation) [0x00024] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.MobileAuthenticatedStream.ProcessAuthentication (System.Net.LazyAsyncResult lazyResult) [0x00057] in <344dc4d3f1ad41809df78607b6121a41>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in /Users/builduser/buildslave/mono/build/mcs/class/referencesource/mscorlib/system/runtime/exceptionservices/exceptionservicescommon.cs:151
at Mono.Net.Security.MobileAuthenticatedStream.ProcessAuthentication (System.Net.LazyAsyncResult lazyResult) [0x00078] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.MobileAuthenticatedStream.AuthenticateAsClient (System.String targetHost, System.Security.Cryptography.X509Certificates.X509CertificateCollection clientCertificates, System.Security.Authentication.SslProtocols enabledSslProtocols, System.Boolean checkCertificateRevocation) [0x0000c] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.Private.MonoSslStreamWrapper.AuthenticateAsClient (System.String targetHost, System.Security.Cryptography.X509Certificates.X509CertificateCollection clientCertificates, System.Security.Authentication.SslProtocols enabledSslProtocols, System.Boolean checkCertificateRevocation) [0x00006] in <344dc4d3f1ad41809df78607b6121a41>:0
at Mono.Net.Security.MonoTlsStream.CreateStream (System.Byte[] buffer) [0x0007b] in <344dc4d3f1ad41809df78607b6121a41>:0
at System.Net.WebConnection.CreateStream (System.Net.HttpWebRequest request) [0x00073] in <344dc4d3f1ad41809df78607b6121a41>:0
--- End of inner exception stack trace ---
at System.Net.HttpWebRequest.EndGetResponse (System.IAsyncResult asyncResult) [0x00058] in <344dc4d3f1ad41809df78607b6121a41>:0
at System.Net.HttpWebRequest.GetResponse () [0x0000e] in <344dc4d3f1ad41809df78607b6121a41>:0
at NugetForUnity.NugetPackageSource.GetPackagesFromUrl (System.String url) [0x00089] in <4e881643001441888fae657e4de10c62>:0
UnityEngine.Debug:LogErrorFormat(String, Object[])
NugetForUnity.NugetPackageSource:GetPackagesFromUrl(String)
NugetForUnity.NugetPackageSource:Search(String, Boolean, Boolean, Int32, Int32)
NugetForUnity.NugetHelper:Search(String, Boolean, Boolean, Int32, Int32)
NugetForUnity.NugetWindow:UpdateOnlinePackages()
NugetForUnity.NugetWindow:DrawOnlineHeader()
NugetForUnity.NugetWindow:DrawOnline()
NugetForUnity.NugetWindow:OnGUI()
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
Unfortunately, I've never tested NuGetForUnity on a Mac.
Searching on Google showed me that at least one other person is having a similar problem with using .NET 4.6 in Unity 2017 on Mac: https://issuetracker.unity3d.com/issues/mac-dot-net-4-dot-6-system-dot-net-dot-webexception-error-in-net-4-dot-6
I'll continue to investigate, but without a Mac progress will be slow.
@GlitchEnzo I am also having System.DllNotFoundException: Security only in mac and iOS, is that because I need to install openSSL? @CasterKKK Did you find any solution to this?
Closing as very old and not being reported by others.
Unity version: 2017.2.0b11
When searching for the Nuget package, the error message after is shown.
I wonder why I cannot use the Nuget package installed by the visual studio?