ERR_HTTP_HEADERS_SENT: Cannot set headers after they are sent to the client
I'm facing this weird issue in NodeJS when using with Passport.js, Express and Mongoose. Basically, I get an error saying "Cannot set headers after they are sent to the client" even though I don't sen...
- Modified
- 17 Jan at 05:21
Upgrading to ServiceStack 2.0 breaks /types/typescript rendering
When upgrading from ServiceStack 5.0.3 to 5.2 and then attempting to generate TypeScript DTOs the following example was rendered ``` // @Route("/boms/{sortColumn}/{sortAscending}", "GET") export clas...
- Modified
- 31 Aug at 17:53
Tail docker logs to see recent records, not all
If you use the Coreutils tail command in Linux, you have a -f option that lets you follow a log file from the log's current position (it does not go to the very beginning of the file and display every...
Starting ssh-agent on Windows 10 fails: "unable to start ssh-agent service, error :1058"
When I try to start the ssh-agent on Windows 10 via PowerShell (with elevated right or without) by entering `Start-Service ssh-agent` I get the error > unable to start ssh-agent service, error :1058 ...
- Modified
- 31 Aug at 10:44
JobStorage.Current property value has not been initialized. You must set it before using Hangfire Client or Server API
I am using hangfire in mvc application. I am sending reminder to user for his/her appointment. I have installed hangfire in my app. I have configured hangfire in startup.cs class. But when i run the ...
- Modified
- 31 Aug at 10:41
How to get a value out of a Span<T> with Linq expression trees?
I would like to use Linq expression trees to call the indexer of a `Span<T>`. The code looks like: ``` var spanGetter = typeof(Span<>) .MakeGenericType(typeof(float)).GetMethod("get_Item"); var ...
- Modified
- 31 Aug at 10:18
String interpolation - what does the @ sign inside the curly braces do?
Consider: ``` string newline = "\r\n"; Console.WriteLine($"Hello without at{newline}how are you?"); Console.WriteLine($"Hello with at{@newline}how are you?"); ``` The output of both lines is ident...
How to add a Password input type in flutter makes the password user input is not visible , just like Android Native EditText 's inputtype:password?
i meet a problem that Flutter 's TextInputType do not have a password type: ``` /// All possible enum values. static const List<TextInputType> values = const <TextInputType>[ text, multiline, num...
Why does Redis C# client method .getById() return null?
I'm building a simple blog application in Asp.Net MVC and I want to use a Redis database. I have created a repository for my Users class that contains a few methods (create, getbyid and update). The...
- Modified
- 30 Aug at 19:53
Building out first client using ServiceStack
I'm trying out ServiceStack for connecting to an OAuth2 / JSON service. (C#) First I'm struggling to find a good example of this out there as it appears most examples are using v3 of ServiceStack. S...
- Modified
- 30 Aug at 17:44
JsonResult return Json in ASP.NET CORE 2.1
Controller that worked in ASP.NET Core 2.0: ``` [Produces("application/json")] [Route("api/[controller]")] [ApiController] public class GraficResourcesApiController : ControllerBase { private...
- Modified
- 20 Oct at 10:27
How to deserialize nullable enum with EnumMember attribute in ServiceStack.Text?
This is a follow up question to my these two earlier questions about [ServiceStack.Text](https://github.com/ServiceStack/ServiceStack.Text): [first](https://stackoverflow.com/questions/51854666/how-to...
- Modified
- 30 Aug at 13:20
Vue.js router history mode with ServiceStack routing fallback and Api prefix
1. Every client side route starts with a hash. How can I enable History Mode in Vue Router without disturbing the api routing? 2. Also I would prefer not to have to start my routes with "/api". Clien...
- Modified
- 31 Aug at 07:32
Webpack Middleware Hot Module Replacement with ServiceStack (without MVC)
When I debug my project in VS Code my NET Core Web App serves the content in wwwroot. Is there a way when using ServiceStack to also add the Webpack Middleware used by MVC to enable HMR?
- Modified
- 30 Aug at 08:23
IServiceCollection does not contain a defintion for AddHttpClient
I am trying to use HttpClient in my .net core 2.0 project and for that I have injected HttpClient in my controller. But when I am trying to configure httpclient in my startup.cs I am getting this erro...
- Modified
- 30 Aug at 07:36
How do I use Microsoft.jQuery.Unobtrusive.Ajax with libman (Library manager) asp.net Core 2.1?
I am trying to use unobtrusive ajax to update my partial views. Unfortunately I ran in to a problem when I was about to install the package, since Bower is not working (?) or recommended anymore accor...
- Modified
- 30 Aug at 08:15
WCF Tracing in ASP.NET Core
We used to use WCF over ASP.NET and recently switched to WCF over ASP.NET Core. This was quite hard to implement because ASP.Net Core doesn't support WCF out of the box. For one thing, the whole web.c...
- Modified
- 30 Aug at 06:19
When run a program in C#, all the messages go to the standard output, but the standard error contains nothing
My question is different with [the one identified](https://stackoverflow.com/questions/28392549/cant-get-process-error-output-using-process-errordatareceived-c-sharp). Obviously I have called "BeginEr...
- Modified
- 30 Aug at 09:2
How to exclude specific exception types from Serilog?
I am using Serilog to log information about an `asp.net core 2.1` application hosted on IIS. When exceptions occur, I am informed by email. The thing is, some exceptions happen without hurting the app...
- Modified
- 15 Nov at 20:18
Find duplicate in array with a memory efficient approach
`A` is an array of integers. All the values are between `0` to `A.Length-1` it means `0 <= A[i] <= A.Length-1` I am supposed to find repeating elements; and if there are several repeating elements,...
- Modified
- 1 Sep at 04:58
Unable to read input stream
I am using `ActionFilterAttribute` to get the request before hitting the controller as below : ``` public override void OnActionExecuting(HttpActionContext actionContext) { using (var stream = ...
- Modified
- 7 Sep at 06:58
CPU temperature of Raspberry Pi in C#
I have read a lot of articles and forum posts about this topic, but almost everything is quite complicated and all from over 2+ years ago. So I was wondering, What is the best way tot get the CPU tem...
- Modified
- 1 Sep at 15:55
System.Linq.Expressions exception thrown when using FirstOrDefault in .Net Core 2.1
I am receiving ~300+ exceptions that are spammed in my server output labeled: ``` Exception thrown: 'System.ArgumentException' in System.Linq.Expressions.dll ``` The query I am using is as follows:...
- Modified
- 20 Sep at 14:21
Detected package downgrade: Microsoft.NETCore.App from 2.1.3 to 2.1.0
I try to update my .net solution from .NET Core 1.1 to .NET Core 2.1. I have several .NET Core and .NET standard projects inside, which reference each other and another NuGet packages. After update 'd...
How can you clear a bound property on a Razor Page's model when POSTing?
I have a property that is bound to an input field: When I POST, I tried clearing the `ContactName` property by setting it to NULL or string.Empty, but it doesn't work. What's the proper way to clear o...
- Modified
- 7 May at 03:53