Stay
✅ Prevent carriage return from being added in the new multi-line string literal?
How to prevent
\r
from being added in a multi-line string literal?
C# is adding a \r
after the \n
only in Windows. I know that Windows uses \n\r
to indicate new lines, but can i somehow disable that?14 replies
❔ System.InvalidCastException when connecting to MariaDB in docker
Hello! I have a console application that works fine in Windows and WSL2. For some reason, when running it under docker (linux) with the dotnet-runtime 6.0 image i get an exception when pinging the database
This exception happen when i
OpenAsync
the connection, not while reading anything.
I can login into the database from inside that container just fine with the mariadb-client
What might be causing this?2 replies
Application works on Windows and WSL2 but fails in docker (Linux). Broken pipe
I have an application that establishes a TCP connection to another Java application.
For some reason, when i run both applications in the same docker container (LInux, using the Dev Containers extension of vscode) the dotnet app reads giberish or gets disconnected by the java app because of a "broken pipe" exception.
This does not happen in Windows 10 or WSL2 (Ubuntu).
I understand that without looking at the code this is not a very helpful description, but i can't debug as good as in Rider in vscode and i don't understand why it would fail under a docker container and not on WSL2.
1 replies
[ASP.NET Core] Apply a selfsigned certificate to asp.net core?
So i don't know exactly what i'm doing, but i'm trying to do the following:
Let's say that i have the following domain purchased:
mywebsite.com
. I'm trying to redirect api.mywebsite.com
to localhost by adding in the hosts file
As expected this does not play nice with browsers or other programs, because the certificate provided by ASP.NET Core has nothing to do with mywebsite.com
or api.mywebsite.com
.
I tried creating a self signed certificate like this in Powershell
But i don't know how to use that in ASP.NET Core (if that's even what i have to do to make this work)
So is this possible or using a domain like that in localhost is completly impossible (without warnings atleast)2 replies
EF Core not fetching sub-entities by Id [Answered]
I'm kinda new to EF Core so maybe the terminology is not right.
I have the following models:
Player:
Group:
And tables:
Players:
Groups:
It works fine when adding a player, it inserts the GroupId as i would expect it to, but when fetching
Group is null
Why is this happening?
3 replies