.net-core-3.1

Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=4.0.3.0 [duplicate]

|▌冷眼眸甩不掉的悲伤 提交于 2020-07-16 10:38:50
问题 This question already has answers here : Project build failed while using .net class library in .net core console application (2 answers) .NET Core 2.1 can't reference a .NET Framework 4.7.2 Class library (1 answer) Closed 7 days ago . I have a .net core 3.1 console application which is using a .net framework 4.6.1 class library. I am getting the below exception when running the console application. I have added the System.Configuration.ConfigurationManager version 4.4.0 to both the projects.

Why my Authentication State Provider not work?

血红的双手。 提交于 2020-07-09 14:34:26
问题 I use blazor with server side render and I want to do my own AuthenticationStateProvider, but it's not work and I do not know why. My ovveride method in public class LocalAuthenticationStateProvider : AuthenticationStateProvider : public async override Task<AuthenticationState> GetAuthenticationStateAsync() { if (await _storageService.ContainKeyAsync("User")) { var userInfo = await _storageService.GetItemAsync<LocalUserInfo>("User"); var claims = new[] { new Claim("Email", userInfo.Email),

SSO for .net core 3.1 web api

自作多情 提交于 2020-06-29 03:59:07
问题 We would like to achieve SSO( Google, Microsoft, Twitter, Facebook ) for a .net core 3.1 web api (console api controllers) application. I have gone through few links that achieves this with the help of MVC or angular front end and IdentityServer4 . Our application is purely an web api. Can some one guide me with sample code or link to achieve this? How does SignInWithGoogle/FB/Twitter/Microsoft button and its click will be handled? 来源: https://stackoverflow.com/questions/62173069/sso-for-net

Error: Failed to complete negotiation with the server: Error: Not Found

不羁的心 提交于 2020-06-17 15:51:38
问题 I'm using SignalR with ASP.NET Boilerplate .NET Core 3.1 but I encounterd this problem Error: Failed to complete negotiation with the server: Error: Not Found How could I resolve this problem without skip negotiate (solution mentioned here ) zone-evergreen.js:2845 POST http://localhost:21021/signalr/negotiate?enc_auth_token=wNYmO41%2F Show 162 more frames signalr.min.js:16 [2020-06-07T10:17:31.634Z] Error: Failed to start the connection: Error: Not Found here is Angular Code: ngOnInit(): void

How to handle Appsettings for .net core 3.1 self contained single file publish

老子叫甜甜 提交于 2020-06-15 16:10:09
问题 I have a new .NET Core 3.1 worker class that is hosted as a Windows Service. I am using the default appsettings.json and appsettings.environment.json that were created by the template. The appsettings is loaded from the hostContext during ConfigureServices .ConfigureServices((hostContext, services) => { services.AddHostedService<Worker>(); services.Configure<BasicSettings>(hostContext.Configuration.GetSection("AppSettings")); }); I want to be able to edit the appsettings after it is deployed

How to handle Appsettings for .net core 3.1 self contained single file publish

筅森魡賤 提交于 2020-06-15 16:07:50
问题 I have a new .NET Core 3.1 worker class that is hosted as a Windows Service. I am using the default appsettings.json and appsettings.environment.json that were created by the template. The appsettings is loaded from the hostContext during ConfigureServices .ConfigureServices((hostContext, services) => { services.AddHostedService<Worker>(); services.Configure<BasicSettings>(hostContext.Configuration.GetSection("AppSettings")); }); I want to be able to edit the appsettings after it is deployed

memory leak cant find where the allocations originate from or why they being held

回眸只為那壹抹淺笑 提交于 2020-06-01 07:38:26
问题 .net memory profiler https://memprofiler.com/ to try and see if i have any memory leaks... See screenshot From the screenshot it very much looks like i do have one. But its extremely hard to tell. Is anyone else Familiar enough with this profiler to try guide me. I have spent white a bit of time i have also tried jetbrains dotmemory Problem is, i cant tell if this is actually leak Or Entity Framework core bug or feature? and to me it make no sense. obviously i know you wont know my code base

Visual Studio 2019 creating .NetStandard 2.0.3 libraries instead of 2.1 inside a .Net Core 3.1 solution

☆樱花仙子☆ 提交于 2020-05-30 05:16:56
问题 i've recently (yesterday) updated visual studio 2019. I have access to .net core 3.1 sdk and can create .net core 3.1 projects. However, when i try to create a .net standard library, it defaults to 2.0.3 instead of 2.1. As far as i understand, .net standard 2.1 should come with .net core 3.1. Am i misunderstanding something here? 回答1: Create a blank solution and add a new Class Library (.NET Standard) . In properties change the target framework to .NET Standard 2.1 Save the changes and click

Visual Studio 2019 creating .NetStandard 2.0.3 libraries instead of 2.1 inside a .Net Core 3.1 solution

人盡茶涼 提交于 2020-05-30 05:16:01
问题 i've recently (yesterday) updated visual studio 2019. I have access to .net core 3.1 sdk and can create .net core 3.1 projects. However, when i try to create a .net standard library, it defaults to 2.0.3 instead of 2.1. As far as i understand, .net standard 2.1 should come with .net core 3.1. Am i misunderstanding something here? 回答1: Create a blank solution and add a new Class Library (.NET Standard) . In properties change the target framework to .NET Standard 2.1 Save the changes and click

Visual Studio 2019 creating .NetStandard 2.0.3 libraries instead of 2.1 inside a .Net Core 3.1 solution

时光怂恿深爱的人放手 提交于 2020-05-30 05:15:53
问题 i've recently (yesterday) updated visual studio 2019. I have access to .net core 3.1 sdk and can create .net core 3.1 projects. However, when i try to create a .net standard library, it defaults to 2.0.3 instead of 2.1. As far as i understand, .net standard 2.1 should come with .net core 3.1. Am i misunderstanding something here? 回答1: Create a blank solution and add a new Class Library (.NET Standard) . In properties change the target framework to .NET Standard 2.1 Save the changes and click