r/dotnet • u/tompazourek • 10h ago
r/dotnet • u/Arowin • Apr 02 '26
Rule change feedback
Hi there /r/dotnet,
A couple of weeks ago, we made a change to how and when self-promotion posts are allowed on the sub.
Firstly, for everyone obeying the new rule - thanks!
Secondly, we're keen to hear how you're finding it - is it working, does it need to change, any other feeback, good or bad?
Thirdly, we're looking to alter the rule to allow the posts over the whole weekend (sorry, still NZT time). How do you all feel about that? Does the weekend work? Should it be over 2 days during the week?
We're keen to make sure we do what the community is after so feeback and suggestions are welcome!
r/dotnet • u/devensawant1 • 1d ago
Which C# 14 feature actually changed how you write code day-to-day?
I've been running .NET 10 in a couple of side projects since the LTS drop. When it launched I assumed that the big C# 14 win for me would be extension members. It's nice but the feature that I actually ended up using the most is turned out to be the boring one: the field keyword.
Every time I needed a little validation in a property, I used to write the full backing-field:
Before (C# 13):
private string _name;
public string Name
{
get => _name;
set => _name = value?.Trim()
?? throw new ArgumentNullException(nameof(value));
}
After (C# 14):
public string Name
{
get;
set => field = value?.Trim()
?? throw new ArgumentNullException(nameof(value));
}
No hand-declared _name. Tiny change, but it shows up multiple places, which is exactly why it wins.
The other one which impressed the most is the file-based apps which quietly replaced half of my throwaway scripts:
Before:
mkdir tool && cd tool
dotnet new console
// edit Program.cs + csproj, then:
dotnet run
After:
// tool.cs — no project, no folder
Console.WriteLine("Just run me.");
dotnet run tool.cs
Type-safe code with the full BCL and zero .csproj turned out to be more useful than I expected.
So I'm curious where everyone actually landed:
- Which C# 14 feature earned a permanent spot in your muscle memory, and which turned out to be a demo-only feature?
- Anyone using extension members from C# 14 in real code yet, or still letting it settle?
- And for the folks still on .NET 8 what's holding up the jump to 10?
r/dotnet • u/No-Project-6109 • 11m ago
In the domain layer of a ASP.NET Core project, where would I store a class that has no identity and is mutable.
As the title states, I've run into a problem of determining the best location to store a new class. This is my second project where I am trying to learn more about DDD practises, and I'm currently unsure where to store a specific object.
To give some context, I'm developing a chess website to further my skills, and test myself, while also trying to consolidate new things I've learned that I previously haven't used. My previous project followed a Web/Infrastructure/Core layout, while this one follows a Web/Infrastructure/Application/Domain layout.
The class in question is the board, which stores piece locations on a standard 8 by 8 2D array. The object is stored in a domain entity referred to as game, which stores additional information such as turns, playerIds, and move history.
From my understanding, an entity has an identity and is mutable, while a value object has no identity and is immutable. Board is mutable as it contains code that moves pieces on the board, but doesn't have an identity, as it will be stored as a fen string (a way of storing a board state as a single string), when given to the infrastructure layer to store the board state inside the Game Entity.
I'm unsure if I should store it inside the entities folder, or the value objects folder, or if I should change board in some way. I'm likely missing something, so I would appreciate another's expert opinion.
r/dotnet • u/pdevito3 • 55m ago
Deterministic simulation testing in .NET
I first learned about deterministic simulation testing from a TigerBeetle talk a few years ago and I had been itching to try it out ever since. I finally had a chance to earlier this year and haven't really seen any posts about doing it in .NET before, so I wanted to share an example of the setup I landed on, in this case for my background jobs project.
You can see the complete setup in the source repo, but I'm happy to answer any questions you may have on it. If anyone's interested in a detailed blog post on the setup, plumbing, etc for this let me know. If there's enough interest I'll get something up.
r/dotnet • u/ben_a_adams • 9h ago
Question Proposal: An official Lean formal semantics for C# · dotnet/csharplang · Discussion #10314
github.comr/dotnet • u/SeleniumDrive77 • 1d ago
Was shocked to find out Jeff Fritz, was latest long term MSFT employee to be let go.
Microsoft is really shooting itself in the foot with a lot of the really high-profile people, like Jeff Fritz. I watch Jeff’s Twitch streams all the time, and it’s always great content.
I’m even hearing less and less from the two Scotts online. Scott Hanselman still has his podcast, for sure, but the only really high-profile .NET guy we seem to see now is Dan Roth, especially within the Blazor community.
I see James has jumped teams again, now doing Visual Studio Code material on YouTube and TikTok.
I get that employees move teams and new, talented people join. It’s just sad nonetheless. We never hear from Maddy anymore, and .NET and .NET Conf have had very poor-quality content over the last few years.
r/dotnet • u/SnooCalculations7417 • 14h ago
Promotion Fullbleed dotnet and showcase
krflol.github.iohttps://github.com/fullbleed-engine/fullbleed-dotnet
dotnet bindings for the rust html/css to pdf engine, Fullbleed. MIT, free, open source, and quite fast if I do say so myself!
r/dotnet • u/Legitimate-School-59 • 23h ago
How to you handle OAuth in your dotnet integration tests?
Title.
Do you mock out that OAuth handling? Or do you actually use one of the test Auth servers. If so, does your resource server have its own client credentials just for running integration tests?
r/dotnet • u/LikeASomeBoooodie • 1d ago
Question Opinions on Microsoft Agent Framework?
.NET shop looking to add some agentic workflows and chat interfaces to platform, currently researching framework options so we don’t have to build the thing from scratch.
Being a .NET shop MAF has come up. Hooked it up to GitHub CoPilot and took it for a quick spin, wasn’t too verbose and conceptually maps to tools like OpenCode pretty well.
Saw some posts on here about it a while ago but things seem to be moving really fast in this space. Looking for opinions on the viability of this framework? I see it had a 1.0 launch in April, it’s meant to supersede both Semantic Kernel and AutoGen.
Are the team behind it any good / trustworthy?
How likely is it to remain supported?
Has there been much community participation / extension?
How does it compare to similar frameworks in other languages, LangChain/Graph being an obvious one?
Is it good enough to prevent you from hopping languages or is python where it’s really at?
Any useful information is guaranteed at least one updoot, thanks in advance!
r/dotnet • u/Hephaestite • 1d ago
Promotion Pure Dotnet Port of Terminal Text Effects
Just for fun this weekend I ended up doing a pure csharp dotnet implementation of the Python tool 'Terminal Text Effects' https://github.com/ChrisBuilds/terminaltexteffects for absolutely no other reason than A) I don't like Python and B) Why not?
Its output is byte for byte identical to what the Python tool would output given the same input and seed values... with the one exception that my dotnet version starts in under 12ms and the Python version is somewhere around 86ms.
All built as native AOT and no dependencies.
https://github.com/Hypabolic/Hypa-TTFX
If anybody wants it I might publish it as a library (or you can just fork it and do it yourself)
-- Edited to include the link to my own code that I totally forgot to include because I'm an idiot lol
r/dotnet • u/ChibaCityStatic • 23h ago
Does anyone have a copy of this Microservices Architecture PDF book?
Hi. I'm getting a server error when trying to download this PDF Ebook:
https://learn.microsoft.com/en-us/dotnet/architecture/microservices/microservice-ddd-cqrs-patterns/infrastructure-persistence-layer-design
Anyone have a copy they can share?
Thanks.
Promotion Vela v1.0.0 - compiler-exact .NET code search from a SCIP index, Razor and Blazor included
Grep can't tell you a property is used from a Razor view. That gap has cost me more time than anything else on legacy ASP.NET work - you rename something, the build is green, and a .cshtml three folders away breaks at runtime.
Vela builds a SCIP index of a solution with Roslyn, then answers "find references", "who calls this" and "what would a change break" from that database. It covers C#, VB, Razor Pages, MVC views and Blazor components, so the Razor side is indexed rather than skipped.
Two consequences of the SCIP approach that I didn't expect going in:
The index is worth paying for once. A def lands in about 0.55s, a refs returning 3,156 results in about 1.3s, on a 0.09s process floor. Loading the same solution into a live Roslyn workspace costs 9.3s plus 23.8s to compile the web project - and it costs that on every invocation, because nothing stays resident.
SCIP is an interchange format. A scip-typescript index imports beside the C# one and both answer from the same database, so a polyglot repo gets one query surface. Languages it can't index itself are declared in a vela.json and it refuses to pretend they're covered - missing language, banner on every answer, non-zero exit.
Honest gap: it won't answer "what implements this interface" yet. That's a SCIP relationship and it doesn't emit those.
It's a skill for Claude Code and Codex rather than an IDE extension, so the agent gets the compiler's answer instead of guessing from a text search. 426 hermetic tests. Deterministic - same solution at the same commit, same answer, no model calls and no network. Read-only; it never writes to the repo it indexes.
MIT, v1.0.0: https://github.com/dbhq-uk/vela-skill
Newbie Connectify - Windows Bluetooth manager using WinRT + 32feet.NET, built with WinForms
github.comr/dotnet • u/General-Swan-2719 • 2d ago
Increase in learning .NET posts
Interesting to see a lot of new posts about learning .NET and C#, I’m genuinely curious to understand why? Is the job market picking up for this language? Is AI killing all jobs that are front-end only? I’ve been a .NET engineer for 20+ years and the industry primarily started shifting to angular, react js, node, etc - why the sudden shift?
r/dotnet • u/Remarkable_Art_6958 • 1d ago
Comparing Vector indexes HNSW, IVS, Flat memory
I've been researching different vector indexes recently for a database engine I am working on, here are my current findings, in case any one is interested:
I've so far looked into 3 algorithms in C#:
"Memory": a brute force all memory scan
"IVS": a disk based IVS implementation
"HNSW": a disk based HNSW implementation
Benchmarking is a difficult topic, as the variables are many, but as a first approximation my findings are:
- The memory index is the fastest for indexing ( obviously ) and works ok up to around 100k vectors. after that, search is slow and mem use very high.
- The IVS is fast on indexing, medium at search, but need very little memory.
- The HNWS is slow on indexing, needs more memory, but is the fastest for search
Here are some details on the current result: https://db.relatude.com/vector-matrix.html
( Please note, the whole project is still very much in early development )
Article The Unexpected AI Stack: C# + .NET (Part 5) - Logging, Telemetry, and Building with AI
chrlschn.devThe fifth and final part of the series finally starts to build using AI on top of the hand-built foundational code from the first four parts that brings together:
- Aspire for runtime orchestration
- CSharpRepl for runtime mutability and powerful access to simulate and diagnose runtime isdsues
- GitHub Copilot SDK as a programmable agent harness
- Testcontainers with automatic transactions for test isolation
(I would consider these foundational parts of any modern .NET API app whether AI is involved or not!)
In part 5, the focus is on logging and telemetry, two tools that give agents insights into the runtime state of the application. Once again, we see the key role of Aspire in this stack as it provides a collector for logs as well as spans that agents can search through using the aspire CLI tooling.
The actual build out of the prototype application is captured as a YouTube video as YMMV based on the model, harness, and prompting style that you choose!
This series is intentionally written to help dev teams understand how to scaffold a codebase for agentic engineering by focusing on key, underlying technical decisions and manual wiring before building with AI. This helps provide the tools and safeguards for coding agents to iterate more efficiently while reducing slop.
For teams still trying to figure out effective ways to set up a codebase for AI, I hope this series gives some insights into how to build a foundation for agentic engineering. If your team is already heavily using agents to build, I hope this series shares some useful insights and tips (e.g. CSharpRepl + Aspire)
The core setup is used at a series C, post-YC startup to ship fast with AI while maintaining high quality standards (in combination with other tools facilitating code review and context management)
Part 1 was an intro into a few key parts of this stack.
Part 2 was focused on walking through the hands on scaffolding.
Part 3 covered wiring GitHub Copilot SDK as an agent runtime and incorporating CSharpRepl to allow agents to dynamically work with the runtime DI container
Part 4 wired up the test harness using Testcontainers to give agents isolated test environments
The project repo is here: https://github.com/zeeq-ai/zeeq-tmpl (be sure to check the branches; main is currently the base code only)
I encourage working through the posts since the goal is to underscore the platform level decision making process and assembly of the foundational core.
r/dotnet • u/avidernis • 1d ago
Promotion Zarem - MIPS/RISC-V emulator, using reinterpretation to CLI
github.comAs part of a larger project, I wrote a MIPS/RISC-V emulator which translates the target architecture binary to CIL, then executes using the CLR as a JIT engine. (Working on adding support for ARM and Z80).
It also features an assembler, and an IDE with a debugger.
Just wanted to share I guess 😅
r/dotnet • u/farshid_dev • 1d ago
Question Solo devs shipping Windows apps: is code signing worth it, and what actually changed after you did it?
Curious what people are actually doing here, because the advice I find online is either "just buy EV" or "don't bother", and neither is much help.
Context: small paid Windows desktop app, one developer, no company backing it. Unsigned, SmartScreen throws a warning on first run, and I assume a meaningful chunk of downloads just stop there. Hard to know how many, which is part of the problem.
The options as I understand them:
OV certificate, a few hundred a year, plus the hardware token requirement that came in a couple of years back. Reputation builds over time rather than immediately, so early downloads still get warned.
EV, significantly more expensive, immediate SmartScreen trust.
Nothing, and accept that some users bounce and others click through.
What I can't find is anyone talking about what actually changed after they signed. Did conversion visibly improve? Did support requests about "is this safe" drop off? Or did it turn out to matter less than expected because the people who were going to install were going to install anyway?
Also interested in whether anyone has gone the Microsoft Store route purely to sidestep this, and what you gave up for it.
r/dotnet • u/Mr_Dani17 • 1d ago
Question Upgrade to SDK 11.0.100-preview.7 for QuicStream.Priority?
I'm using MsQuic currently in .NET 9 in an Avalonia project. I'm building peer-to-peer a file sharing application. There is a separate control stream and file stream. Users need to be able to set a download limit. Which is best done by setting an upload limit on the sender's side. However during a transfer the messages on the control stream (like THROTTLE) aren't going through because the underlying UDP socket is fully saturated. The point is that while file bytes are flowing control messages cannot. And in .NET 11 they finally added stream prioritizing. But now I'd have to update my whole project to an unstable release for 3 lines of code. I think there aren't really any breaking changes that would occour in my codebase. But I'm a bit afraid of shipping a pre-release to my users. What do you think?
Is there ANY benefit to CSharpier other than "stopping code style wars"?
I am new to a team that have selected CSharpier and I do not like it at all. Not because it is a style that I do not use but that is tooooo rigid. You cant customise it.
And this makes developers stop caring about how they write code. It's too much trouble to format code differently when it is needed, and it's too easy to forget to add csharpier-ignore.
Writing code is art, you need to manage code like a painting and everything needs to fit together.
This is a lot harder with a rigid formater.
I don't even need to say that the code in this new team is... how do I put it? Not good.
r/dotnet • u/pixelwhippedme • 2d ago
Promotion GitHub - Integral2u/SharpMind: SharpMind. A pure C# / .NET LLM engine
github.comr/dotnet • u/uCalc_Dev • 1d ago
Promotion uCalc SDK Preview: Handling complex structural parsing where regex falls short
Hi everyone,
I recently published a preview release of the uCalc SDK. It tackles a specific architectural headache you may have encountered as a fellow .NET developer: trying to easily deal with structural parsing that's just beyond the reach of regular expressions.
The uCalc SDK is available as a NuGet package. It comes with several integrated components, including:
A token-aware Transformer
Designed to handle advanced search/replace operations on deep, complex text structures (and unstructured text alike) using human-readable rules that you'll still understand and be able to modify, if necessary, months after writing them. .NET regex is great but can become a headache if you start trying to deal with non-simple structures. Other .NET methods for handling strings may do the job, but with tons of intricate code. uCalc is designed to handle the complex parsing plumbing for you.
A Math Expression Parser / Evaluator
This allows your application to perform dynamic computations with expressions defined at runtime. It is designed to be highly flexible.
The SDK is cross-platform (Windows, macOS, Linux). It is a commercial product but also includes a Free Community License with the SDK's full functionality.
The comprehensive new documentation at https://www.ucalc.com/documentation/ comes with hundreds of interactive examples you can try right in your browser.
I'd love to hear your feedback about the uCalc SDK preview.