Telerik.Everlive.SDK File Upload Error - Bad Gateway 502 - telerik

I am trying to upload a file ("abc.jpg") using Telerik.Everlive.SDK library, but I keep getting bad gateway error.
Here is my code:
var fileField = new Telerik.Everlive.Sdk.Core.Query.Definition.FormData.FileField("file","abc.jpg","image/jpeg", stream);
var result = EverliveAppContext.WorkWith().Files().Upload(fileField).ExecuteSync();
I am getting following exception while executing above code:
Telerik.Everlive.Sdk.Core.Transport.EverliveException: \r\n502 Bad Gateway\r\n\r\n502 Bad Gateway\r\nnginx\r\n\r\n\r\n ---> System.Net.WebException: The remote server returned an error: (502) Bad Gateway.\n at System.Net.HttpWebRequest.CheckFinalStatus (System.Net.WebAsyncResult result) [0x0033b] in :0 \n at System.Net.HttpWebRequest.SetResponseData (System.Net.WebConnectionData data) [0x00165] in :0 \n --- End of inner exception stack trace ---\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000b] in :0 \n at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0004e] in :0 \n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x0002e] in :0 \n at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x0000b] in :0 \n at System.Runtime.CompilerServices.TaskAwaiter`1[Telerik.Everlive.Sdk.Core.Model.Result.CreateResultItem].GetResult () [0x00000] in :0 \n at Stream.Data.Repository+Files+d__1.MoveNext () [0x0008f] in e:\PROJECTS\GIT\StreamLive\common\Entities\Repository.cs:218

Related

Blazor Hosted WebApp - Error after publishing

I have started learning Blazor Webassembly using the Hosted model.
Locally I can create and run a simple Blazor web application using visual studio code.
However, when I publish (in this case to www.myasp.net) the following scripting error occurs on any page:
Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
Unhandled exception rendering component: Unexpected token < in JSON at position 0
SyntaxError: Unexpected token < in JSON at position 0
Microsoft.JSInterop.JSException: Unexpected token < in JSON at position 0
SyntaxError: Unexpected token < in JSON at position 0
at System.Threading.Tasks.ValueTask`1[TResult].get_Result () <0x21ea748 + 0x0002c> in :0
at Microsoft.JSInterop.JSRuntimeExtensions.InvokeVoidAsync (Microsoft.JSInterop.IJSRuntime jsRuntime, System.String identifier, System.Object[] args) <0x2010058 + 0x000e4> in :0
at
Thank you
Here is the full error:
Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
Unhandled exception rendering component: Unexpected token < in JSON at position 0
SyntaxError: Unexpected token < in JSON at position 0
Microsoft.JSInterop.JSException: Unexpected token < in JSON at position 0
SyntaxError: Unexpected token < in JSON at position 0
at System.Threading.Tasks.ValueTask1[TResult].get_Result () <0x21ea748 + 0x0002c> in <filename unknown>:0 at Microsoft.JSInterop.JSRuntimeExtensions.InvokeVoidAsync (Microsoft.JSInterop.IJSRuntime jsRuntime, System.String identifier, System.Object[] args) <0x2010058 + 0x000e4> in <filename unknown>:0 at Microsoft.AspNetCore.Components.WebAssembly.Authentication.RemoteAuthenticationService3[TRemoteAuthenticationState,TAccount,TProviderOptions].EnsureAuthService () <0x20084c0 + 0x000ee> in :0
at Microsoft.AspNetCore.Components.WebAssembly.Authentication.RemoteAuthenticationService3[TRemoteAuthenticationState,TAccount,TProviderOptions].GetAuthenticatedUser () <0x2007c20 + 0x000d2> in <filename unknown>:0 at System.Threading.Tasks.ValueTask1[TResult].get_Result () <0x21ebf88 + 0x0002c> in :0
at Microsoft.AspNetCore.Components.WebAssembly.Authentication.RemoteAuthenticationService3[TRemoteAuthenticationState,TAccount,TProviderOptions].GetUser (System.Boolean useCache) <0x1fcb190 + 0x00136> in <filename unknown>:0 at Microsoft.AspNetCore.Components.WebAssembly.Authentication.RemoteAuthenticationService3[TRemoteAuthenticationState,TAccount,TProviderOptions].GetAuthenticationStateAsync () <0x1fc9ff0 + 0x000d0> in :0
at Microsoft.AspNetCore.Components.Authorization.AuthorizeViewCore.OnParametersSetAsync () <0x2135338 + 0x0012e> in :0
at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion (System.Threading.Tasks.Task task) <0x2135d90 + 0x000ee> in :0
at Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync () <0x1f67eb0 + 0x0020c> in :0
at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask (System.Threading.Tasks.Task taskToHandle) <0x21391a0 + 0x000ca> in :0
Yes,
The hosting provider granted the application pool full access to the root folder (the folder just beneath the wwwroot folder) This solved the problem for me.
Since I am forcing my website to use https I also had to obtain a .pfx copy of my certificate with a private key - which I then include in the appsettings.json file
"IdentityServer": {
"Clients": {
"xxxxxxxxx.Client": {
"Profile": "IdentityServerSPA"
}
},
"Key": {
"Type": "File",
"FilePath": "xxxxxxxxx.pfx",
"Password": "xxxxxxxxx"
}
}

How to properly map an expected DLL name to a native Mac framework for Mono

I am trying to use the Chromium Embedded Framework.framework in my Mac app. In my sample .net code, this framework is referenced as libcef.dll. When I call a method on the framework, I get a System.DllNotFound exception. I have looked at DLL maps to map the CEF framework on the Mac to the expected DLL name of libcef.dll and I have the following map but this did not resolve the issue.
<configuration>
<dllmap dll="libcef.dll" target=" /Library/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework"/>
</configuration>
I have also added the framework to my project within Visual Studio 2017 for Mac as a native reference but nor did this resolve the issue.
Does anyone know how I might be able to get around this DllNotFound exception?
Here is the stack track that I get when the DLLNotFound Exception is thrown:
System.DllNotFoundException: libcef
at at (wrapper managed-to-native) Xilium.CefGlue.Interop.libcef:api_hash (int)
at Xilium.CefGlue.CefRuntime.CheckVersionByApiHash () [0x00002] in /Users/jlaase/Documents/dev/xilium.cefglue/CefGlue/CefRuntime.cs:106
at Xilium.CefGlue.CefRuntime.CheckVersion () [0x00002] in /Users/jlaase/Documents/dev/xilium.cefglue/CefGlue/CefRuntime.cs:92
at Xilium.CefGlue.CefRuntime.Load () [0x0000c] in /Users/jlaase/Documents/dev/xilium.cefglue/CefGlue/CefRuntime.cs:81
at System.Threading.Tasks.Task.InnerInvoke () [0x0000f] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/threading/Tasks/Task.cs:2879
at System.Threading.Tasks.Task.Execute () [0x00010] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/threading/Tasks/Task.cs:2502
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/exceptionservices/exceptionservicescommon.cs:152
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x00037] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:187
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:156
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:128
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () [0x00000] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:113
at Demo.CefGlue.AppDelegate+c__async0.MoveNext () [0x00099] in <6839508fd4284d13b86c5e47bd563ec6>:0
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/exceptionservices/exceptionservicescommon.cs:152
at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.b__6_0 (System.Object state) [0x00000] in /Users/builder/data/lanes/4992/mono-mac-sdk/external/bockbuild/builds/mono-x64/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/AsyncMethodBuilder.cs:1018
at MonoMac.AppKit.AppKitSynchronizationContext+c__AnonStorey0.<>m__0 () [0x00000] in <69849e6b886848f68ef0f56b62fe76aa>:0
at MonoMac.Foundation.NSAsyncActionDispatcher.Apply () [0x00002] in <69849e6b886848f68ef0f56b62fe76aa>:0
at at (wrapper managed-to-native) MonoMac.AppKit.NSApplication:NSApplicationMain (int,string[])
at MonoMac.AppKit.NSApplication.Main (System.String[] args) [0x0003d] in <69849e6b886848f68ef0f56b62fe76aa>:0
at Demo.CefGlue.MainClass.Main (System.String[] args) [0x00006] in <6839508fd4284d13b86c5e47bd563ec6>:0
Thanks,
Josh

Xamarin Studio community treats handled exception as unhandled exception

I have this problem where I get unhandled exception crash on my Xamarin Android app. I'm trying to login user into parse.com using user session token. The statements are put inside try-catch block to catch exceptions. But catch block fails to catch "Invalid session token" error from parse.com and app crashes. Catch block works fine if I manually tamper sessionToken.
Here's what I am doing
try {
await ParseUser.BecomeAsync(sessionToken);
...
} catch (Exception e){
//log exception
}
when there is invalid session token error, above code crashes saying "unhandled exception...." even though it was put inside try block.
following code works. (manually tampering token)
try {
await ParseUser.BecomeAsync(sessionToken + "test");
...
} catch (Exception e){
//log exception
}
Parse component from Xamarin Component store
What am I missing?
Also, same code works just fine with Xamarin.iOS.
EDIT Adding StackTrace
at Parse.Internal.ParseCommandRunner+<>c__DisplayClass2.<RunCommandAsync>b__1 (System.Threading.Tasks.Task`1[TResult] t) [0x000eb] in <5d1c0c2b96a7483d85e5c63b3e156125>:0
at Parse.Internal.InternalExtensions+<>c__DisplayClass1`2[TIn,TResult].<OnSuccess>b__0 (System.Threading.Tasks.Task t) [0x00000] in <5d1c0c2b96a7483d85e5c63b3e156125>:0
at Parse.Internal.InternalExtensions+<>c__DisplayClass7`1[TResult].<OnSuccess>b__6 (System.Threading.Tasks.Task t) [0x0006f] in <5d1c0c2b96a7483d85e5c63b3e156125>:0
at System.Threading.Tasks.ContinuationResultTaskFromTask`1[TResult].InnerInvoke () [0x00024] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Threading.Tasks.Task.Execute () [0x00010] in <3fd174ff54b146228c505f23cf75ce71>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <3fd174ff54b146228c505f23cf75ce71>:0
at Parse.Internal.InternalExtensions+<>c__DisplayClass7`1[TResult].<OnSuccess>b__6 (System.Threading.Tasks.Task t) [0x00033] in <5d1c0c2b96a7483d85e5c63b3e156125>:0
at System.Threading.Tasks.ContinuationResultTaskFromTask`1[TResult].InnerInvoke () [0x00024] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Threading.Tasks.Task.Execute () [0x00010] in <3fd174ff54b146228c505f23cf75ce71>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <3fd174ff54b146228c505f23cf75ce71>:0
at Parse.Internal.InternalExtensions+<>c__DisplayClass7`1[TResult].<OnSuccess>b__6 (System.Threading.Tasks.Task t) [0x00033] in <5d1c0c2b96a7483d85e5c63b3e156125>:0
at System.Threading.Tasks.ContinuationResultTaskFromTask`1[TResult].InnerInvoke () [0x00024] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Threading.Tasks.Task.Execute () [0x00010] in <3fd174ff54b146228c505f23cf75ce71>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <3fd174ff54b146228c505f23cf75ce71>:0
at System.Runtime.CompilerServices.TaskAwaiter`1[TResult].GetResult () [0x00000] in <3fd174ff54b146228c505f23cf75ce71>:0
at Hyphen_App.Droid.SplashActivity+<setCurrentUser>d__4.MoveNext () [0x00035] in /Chethan Shetty/GIT/android-parent/Hyphen_App.Droid/Splash/SplashActivity.cs:112
EDIT 1 After changing setCurrentUser to following, I am able to catch the exception but after 3-4 seconds app crashes by itself giving " System.AggregateException"
void setCurrentUser(string sessionToken,Action<bool> callback){
try {
ParseUser.BecomeAsync(sessionToken).Wait();
callback(true);
}catch(AggregateException e){
e.Handle( x => { return true; });
callback(false);
}
Like you said in the comments you were calling the async method in your OnCreate without awaiting it.
It can cause the Exception not to be caught, if the somewhere in the async stack a task is not awaited.
I hope it helped you resolve the issue.
Update
Sorry for not expressing me clearly. Your code must look something like that:
protected override async void OnCreate(Bundle savedInstanceState)
{
base.OnCreate(savedInstanceState);
await this.SetCurrentUser();
}
private async Task<bool> SetCurrentUser(string sessionToken)
{
try {
await ParseUser.BecomeAsync(sessionToken);
} catch (Exception e) {
return false;
}
}
to use the await keyword was what i was referring to when saying 'awaiting'.
With the async / await keywords in C#, callbacks are rarely used in asynchronous scenarios anymore. There is a short introduction over at microsoft docs

Xamarin forms ios images not visible when deployment target is changed

I'm working on a Xamarin forms project. The problem is in my Xamarin forms ios project when I set my deployment target as 6 all the images are visible when run on simulator, but when I change my deployment target to 9.0, none of the images are visible. I don't know how to resolve this issue.
with deployment target 9.0 i'm getting the below exception.
Could not initialize an instance of the type 'UIKit.UIImage': the native 'initWithContentsOfFile:' method returned nil. It is possible
to ignore this condition by setting
MonoTouch.ObjCRuntime.Class.ThrowOnInitFailure to false.at
Foundation.NSObject.InitializeHandle (System.IntPtr handle,
System.String initSelector) [0x00094] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/src/Foundation/NSObject2.cs:465
at UIKit.UIImage..ctor (System.String filename) [0x0002e] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/src/build/ios/native/UIKit/UIImage.g.cs:95
at
Xamarin.Forms.Platform.iOS.ToolbarItemExtensions+SecondaryToolbarItem.UpdateIcon
() [0x00000] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Extensions\ToolbarItemExtensions.cs:142
at
Xamarin.Forms.Platform.iOS.ToolbarItemExtensions+SecondaryToolbarItem..ctor
(Xamarin.Forms.ToolbarItem item) [0x00018] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Extensions\ToolbarItemExtensions.cs:113
at Xamarin.Forms.Platform.iOS.ToolbarItemExtensions.ToUIBarButtonItem
(Xamarin.Forms.ToolbarItem item, System.Boolean forceName) [0x00000]
in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Extensions\ToolbarItemExtensions.cs:28
at
Xamarin.Forms.Platform.iOS.NavigationRenderer+ParentingViewController.UpdateToolbarItems
() [0x0008f] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Renderers\NavigationRenderer.cs:935
at
Xamarin.Forms.Platform.iOS.NavigationRenderer+ParentingViewController.ViewDidLoad
() [0x00044] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Renderers\NavigationRenderer.cs:847
at (wrapper managed-to-native)
ObjCRuntime.Messaging:IntPtr_objc_msgSendSuper (intptr,intptr) at
UIKit.UIViewController.get_View () [0x00030] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/src/build/ios/native/UIKit/UIViewController.g.cs:2716
at
Xamarin.Forms.Platform.iOS.NavigationRenderer.CreateViewControllerForPage
(Xamarin.Forms.Page page) [0x000ee] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Renderers\NavigationRenderer.cs:401
at
Xamarin.Forms.Platform.iOS.NavigationRenderer+<OnPushAsync>d__44.MoveNext
() [0x0000a] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Platform.iOS\Renderers\NavigationRenderer.cs:354
--- End of stack trace from previous location where exception was thrown --- at
System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw ()
[0x0000c] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/referencesource/mscorlib/system/runtime/exceptionservices/exceptionservicescommon.cs:143
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess
(System.Threading.Tasks.Task task) [0x00047] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:187
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification
(System.Threading.Tasks.Task task) [0x0002e] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:156
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd
(System.Threading.Tasks.Task task) [0x0000b] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:128
at System.Runtime.CompilerServices.TaskAwaiter 1[TResult].GetResult ()
[0x00000] in
/Users/builder/data/lanes/3969/44931ae8/source/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/TaskAwaiter.cs:357
at Xamarin.Forms.NavigationPage+<PushAsyncInner>d__90.MoveNext ()
[0x0009a] in
C:\BuildAgent2\work\aad494dc9bc9783\Xamarin.Forms.Core\NavigationPage.cs:358

dnu restore failed on mac with System.ArgumentException: More than one runtime.json file has declared imports for 'osx.10.10-x64'

When I run dnu restore on my solution on mac I got this error :
----------
System.ArgumentException: More than one runtime.json file has declared imports for 'osx.10.10-x64'
Parameter name: runtimeName
at Microsoft.Dnx.Tooling.RestoreCommand.FindRuntimeDependencies (System.String runtimeName, System.Collections.Generic.List`1 runtimeFiles, System.Collections.Generic.Dictionary`2 effectiveRuntimeSpecs, System.Collections.Generic.HashSet`1 allRuntimeNames, System.Func`2 circularImport) <0x2da4820 + 0x001a3> in <filename unknown>:0
at Microsoft.Dnx.Tooling.RestoreCommand.FindRuntimeDependencies (System.String runtimeName, System.Collections.Generic.List`1 runtimeFiles, System.Collections.Generic.Dictionary`2 effectiveRuntimeSpecs, System.Collections.Generic.HashSet`1 allRuntimeNames) <0x2da4720 + 0x000cf> in <filename unknown>:0
at Microsoft.Dnx.Tooling.RestoreCommand+<RestoreForProject>d__69.MoveNext () <0x2d46890 + 0x02767> in <filename unknown>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () <0x188f670 + 0x00035> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) <0x188cfa0 + 0x000b7> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) <0x188cf00 + 0x00087> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) <0x188ceb0 + 0x0003f> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter`1[TResult].GetResult () <0x1b859d0 + 0x0001f> 24211 in <filename unknown>:0
at Microsoft.Dnx.Tooling.RestoreCommand+<>c__DisplayClass68_0+<<Execute>b__2>d.MoveNext () <0x2d46100 + 0x0017f> in <filename unknown>:0
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () <0x188f670 + 0x00035> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) <0x188cfa0 + 0x000b7> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) <0x188cf00 + 0x00087> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) <0x188ceb0 + 0x0003f> in <filename unknown>:0
at System.Runtime.CompilerServices.TaskAwaiter.GetResult () <0x188ce80 + 0x0001f> in <filename unknown>:0
at Microsoft.Dnx.Tooling.RestoreCommand+<Execute>d__68.MoveNext () <0x26f66b0 + 0x00ab3> in <filename unknown>:0
----------
Restore failed
More than one runtime.json file has declared imports for 'osx.10.10-x64'
Parameter name: runtimeName
NuGet Config files used:
/Users/myuser/.config/NuGet/nuget.config
/Users/myuser/Documents/chatle/nuget.config
Feeds used:
https://www.myget.org/F/aspnetvnext/api/v2/
https://www.nuget.org/api/v2/
I use the latest unstable rc2 from aspnetvnext feed
Active Version Runtime Architecture OperatingSystem Alias
------ ------- ------- ------------ --------------- -----
1.0.0-rc1-update1 mono linux/osx
* 1.0.0-rc2-16551 mono linux/osx default
Someone else got this ?
The solution can be downloaded on github
You need imports under dnxcore50 https://github.com/aspnet/Configuration/blob/a7320e6486fcdb8b03279f865250d4ac17676e3e/test/Microsoft.Extensions.Configuration.Test/project.json#L18
Also, you need NetStandard.Library or NetCore.Platforms: https://github.com/aspnet/Configuration/blob/a7320e6486fcdb8b03279f865250d4ac17676e3e/test/Microsoft.Extensions.Configuration.Test/project.json#L10
You might also hit some bugs because we're transitioning to the new TFMs now and dnx currently doesn't handle them correctly.

Resources