Questions tagged [dnx]

As an obsolete concept, the .NET Execution Environment contains the code required to bootstrap and run an application. This includes things like the compilation system, SDK tools, and the native CLR hosts.

Note that DNX is no longer an active term used in .NET Core ecosystem, and you should migrate to .NET Core CLI.

The .NET Execution Environment contains the code required to bootstrap and run an application. This includes things like the compilation system, SDK tools, and the native CLR hosts.

Goals

  • Create a new development experience that enables a quick development workflow (change code and run)
  • Have the ability to create a cached version of your application's dependencies ("compilation")
  • Expose metadata about the runtime for others to query

Principles

  • NuGet all the things
  • There is no such thing as "design time" (blur the lines between compilation and loading)
  • Dependencies are always described as what not where (there's no such thing as a project/nuget/assembly reference)
706 questions
28
votes
7 answers

Show ASP.NET 5 error page in Azure web app

I am getting a 500 Internal Server Error when deploying our ASP.NET 5 web application to an Azure Web App. How do I get the details and stacktrace for this exception? I have done the following but with no luck: Using the diagnostics error page on…
Dave New
  • 38,496
  • 59
  • 215
  • 394
27
votes
3 answers

What are the platforms in the .NET Platform Standard?

Currently trying to learn about the .NET Platform Standard I've found myself quite confused about the idea of "different platforms". I'll try to make my point clear. What I currently now about the .NET Framework is that .NET is roughly speaking…
user1620696
  • 10,825
  • 13
  • 60
  • 81
24
votes
5 answers

Write to EventLog in .Net Core

I need a way to write to Windows' event viewer in my app that's using dnx. But, the EventLog class isn't available in the System.Diagnostics namespace so I'm stuck. Is there any other way to write to the EventViewer?
Ameno acids
  • 413
  • 1
  • 4
  • 9
24
votes
2 answers

Running unit tests in TFS/VSO Build vNext using xUnit adapter

I am trying to run our xUnit tests using the xUnit test adapter in Visual Studio Online's Build vNext platform. As stipulated in this article, we need to provide a custom test adapter path pointing to xunit.runner.visualstudio.testadapter.dll. But…
Dave New
  • 38,496
  • 59
  • 215
  • 394
24
votes
1 answer

Running first ASP.NET 5 application using VSCode, DNX and kestrel results in IOException

Following the steps described in the Visual Studio Code documentation, running the final command dnx . kestrel via the Command Palette of VSCode on Mac OS X results in an IOException when visiting http://localhost:5001: kqueue() FileSystemWatcher…
hwschuur
  • 1,101
  • 2
  • 13
  • 17
23
votes
5 answers

ASP.NET 5 An error occurred while starting the application

After publishing an ASP.NET Web App, I'm trying to host the website on my local server. However, when I start it up, it gives me this error in my browser: Oops. 500 Internal Server Error An error occurred while starting the application. How can…
painiyff
  • 2,519
  • 6
  • 21
  • 29
23
votes
2 answers

MemoryCache.Default not available in .NET Core?

I'm porting some code from .NET 4.6 til .NET Core and have run into some problems with MemoryCache. The 4.6 code is using MemoryCache.Default to instantiate the cache, but this doesn't seem to be available in .NET Core. Is there any equivalent to…
henningst
  • 1,664
  • 2
  • 20
  • 30
23
votes
6 answers

"The expected lock file doesn't exist. Please run "dnu restore"" right after I have done so

I'm running beta7 for everything, including EF 7. I'm trying to connect to my remote existing database using the ASP.NET 5 Application template project. My project.json looks like this: { "webroot": "wwwroot", "userSecretsId":…
erictrigo
  • 989
  • 2
  • 13
  • 41
23
votes
1 answer

DNX vs DNX Core

I have started a very simple "kick the tires" ASP.Net MVC (beta) project in VS2015 and am having an issue wrapping my head around the DNX and DNX Core references. In this example I am trying to use DateTime.ToShortDateString() and have the…
Joe
  • 5,389
  • 7
  • 41
  • 63
22
votes
3 answers

Changing the name of the output assembly and package using dnx/.net core

I have a project which exists in a directory named Oracle and I would like the artifacts created to be called MyCompany.MyApp.Oracle instead of Oracle, what are my options for changing the output assembly name and nuget package name outside of…
Damian
  • 2,709
  • 2
  • 29
  • 40
22
votes
3 answers

Why is ASP.NET vNext 'dnu build' not working on OSX

Installed DNVM and DNX on OSX as instructed via https://github.com/aspnet/Home. I used generator-aspnet to create a console application with one source file, Program.cs: using System; namespace HelloWorldConsole { public class Program { …
Ravi Amin
  • 223
  • 2
  • 5
22
votes
6 answers

HttpClient in ASP.NET 5.0 not found?

Using VS2015 and asp.net 5, when I try to compile my site using an instance of System.Net.HttpClient, it tells me: The type or namespace name 'HttpClient' could not be found (are you missing a using directive or an assembly reference?) Hovering…
damccull
  • 3,908
  • 2
  • 17
  • 22
20
votes
2 answers

How to stream a video or a file considering request and response range headers?

I am now using FileStreamResult and it works to stream a video, but can't seek it. It always starts again from the beginning. I was using ByteRangeStreamContent but it seems that it is not available anymore with dnxcore50. So how to proceed ? Do i…
Cristi Pufu
  • 9,002
  • 3
  • 37
  • 43
19
votes
1 answer

RoutePrefixAttribute in ASP.NET 5

I've started a new Web API 2.0 project in ASP.NET 5. I try to create custom RoutePrefixAttribute class but I get this error The type or namespace name 'RoutePrefixAttribute' could not be found (are you missing a using directive or an assembly…
alexxjk
  • 1,681
  • 5
  • 18
  • 30
18
votes
6 answers

MVC 6 Web Api: Resolving the location header on a 201 (Created)

In Web Api 2.2, we could return the location header URL by returning from controller as follows: return Created(new Uri(Url.Link("GetClient", new { id = clientId })), clientReponseModel); Url.Link(..) would resolve the resource URL accordingly…
Dave New
  • 38,496
  • 59
  • 215
  • 394
1
2
3
47 48