Clint McMahon Clint McMahon

How to Fix a Broken .NET App You Just Inherited

This is a post about how I fix .Net apps when I inherit a broken one. This could apply to any other web framework but since I work a lot in .Net, I'm going to use that as an eample.The priority is to get it running, understand the system and identify any risks to the business. Here’s a pretty straightforward process I use to stabilize legacy .NET projects and deliver value quickly.

Step 1: Build and Run

Start by building and running the app in your local environment. If the app builds thats great. If the app doesn't build then you start there. If the problem isn't clear, take the output and run it through your favorite AI system. I use ChatGPT and VS Code Copilot. These are great tools for searching large error logs and code repos to save you time. Document any issues or missing dependencies.

Step 2: System Overview

Review the solution structure, configuration, and any deployment scripts. Map out the main components—APIs, databases, integrations. This gives you a clear picture of what you’re working with. Again, utilizing AI can save a ton of time. With Copilot, using the `ask` mode you can have the system analyze your code repository to deliver an overview of the system and create a set of documentation that you can use to learn and inform the business.

Step 3: Audit for Issues

These are some of the things that I will audit for outstanding issues. These are usually low hanging fruit that I can take care of right away.

Step 4: Stakeholder Input

Talk to previous developers and business owners if possible. I like to ask the question "What is this suppose to do?" as the first question so I can get an idea of what the expectation of the application is. Sometimes the expectation doesn't match what the app is already doing.

There are also times that the client disagrees internally about what the application's purpose is and how it's suppose to work. This is a good time to start writing documentation with the involvement of the business. Writing documentation with the business will yeild clarity and results that the client might not have been thinking about previously.

You want to help clarify what’s broken, what’s working, and what’s most important to fix first. This gives me a clear roadmap of what we are going to do first and how to proceeed down the road.

Step 5: Prioritize and Plan

Address the most critical issues first. What's costing the business money or stopping revenue from coming in? Focus on changes that unblock the team and stabilize the application. Avoid large rewrites at all costs. Unless it's an outdated framework that cannot be upgraded (.Net framework --> .Net Core) then lean towards incremental improvements which are generally safer and more effective.

If you’re dealing with a legacy .NET app, the process above will help you get control and move forward. The goal is to reduce risk, deliver value quickly, and make the system work for the business again. If you need help getting a legacy .NET project back on track, get in touch.