Video summary
Visual Studio continues to evolve as a highly relevant development environment, even in the age of artificial intelligence and Copilot. The presenter emphasizes that while AI models excel at handling trivial background tasks, Visual Studio's true value lies in bridging the gap between developers and Large Language Models (LLMs) to solve complex problems efficiently. To demonstrate this synergy, the speaker walks through a real-world scenario involving a social media recipe application that is struggling with performance issues due to high database loads. The solution involves integrating an external specialized library using Git submodules, a feature now more accessible within Visual Studio. This integration allows developers to manage dependencies locally without cluttering the main codebase, ensuring efficient communication with the database while maintaining a clean project structure.
The core of the demonstration focuses on advanced debugging techniques that leverage both built-in tools and AI assistance. When encountering data corruption or long strings during debugging, the presenter highlights the Text Visualizer's ability to auto-detect encoding formats and decompress data, which is crucial for diagnosing issues like GZIP compression errors. Furthermore, the session introduces enhanced Data Tips that can be pinned to specific locations on the screen, allowing developers to inspect variables continuously without losing context. These tips can even store comments for later reference and are exportable as XML files, enabling senior team members to share debugging insights and hypotheses with colleagues seamlessly.
Beyond local debugging, the video explores how Visual Studio integrates with external services like Azure DevOps and GitHub to streamline the software delivery lifecycle directly from the IDE. Developers can create, review, and merge pull requests without leaving their editor, utilizing agents that analyze code diffs and suggest fixes for issues such as deadlocks or hanging processes. The presenter also details how Copilot can be instructed to investigate crashes using native debugger tools, including disassembly and register inspection, even when source symbols are unavailable. This capability allows the AI to correlate stack pointers and process memory with known issues, providing actionable solutions faster than traditional methods. Ultimately, the talk concludes by reinforcing that Visual Studio is not just an editor but a comprehensive platform that combines decades of accumulated utility with modern AI agents to handle everything from code snippets to complex production debugging.
Read the full video transcript
Welcome to the other programming
features of Visual Studio. My name is
Marco Perro and I'll be uh covering some
of the very old hidden features that
have simply
uh been forgotten over time with all the
exciting new features that we keep
releasing every couple of months.
And out of curiosity, I was wondering
who came to the previous talk in BSLE
2025 where we talked about other hidden
features in Visual Studio. Awesome.
Well, we have been really hard work at
our recipe website from that previous
talk. So you'll see a couple of
improvements there and hopefully you
like how it's uh going so far because we
are very close to release and we just
need to do some updates before we go in
for the rest of the people.
Let's go back. Um feel free to uh
download the slides after this talk if
you're curious about seeing the other
things that we covered during that talk.
They are available in YouTube and
there's a lot that's covered there that
will be also very valuable if you like
the content of this one.
So, Visual Studio is turning 29 years
old. The big question is how long people
have been using Visual Studio. We're
very curious about that. So, out of
curiosity, raise your hand. The people
who have been who have never used VS,
let's start with that.
Awesome. No one. Okay. So we can get to
the little advanced stuff. Less than one
year.
No one. Okay. Dealing with experts here.
One to nine years. Okay. Awesome. I fall
into that category.
10 to 19 years.
Wow. Okay. There might be some features
that I remind you of down the road. Plus
20 years. Okay. Awesome. Well, hopefully
you'll be excited with the new stuff
that we're adding to the product.
All right. So,
with CLI, Copilot, artificial
intelligence, is Visual Studio still
relevant? Absolutely. It's actually more
relevant than ever because nowadays it's
pretty simple to just let Copilot or any
AI model handle the trivial tasks, the
simple things that can be done in the
background. while we now must focus on
the critical stuff, the things that
actually require a little bit more brain
power. And the magic of Visual Studio is
that it is what
bridges that gap with LLMs to uh be able
to find the solutions that we are
looking for easier and faster. We have
been working almost 30 years on adding a
bunch of features and utility to the
IDE. So what we're trying to do with BS
is give them all to copilot and let them
use it and that will be
um where things start shining. So we're
going to go ahead and start with the uh
demo of what I've been working on for
the past year.
So I'll be
You don't see my screen, right? Cool.
Let's share screen.
How about now?
There we go. Okay,
let's start.
As I mentioned from the previous talk,
we worked on a social media app where
people can uh upload their own recipes.
People can uh see them, like them, they
can rate them, and it's a perfect
resource for everyone who wants to learn
to cook more and uh broaden their
options.
Now, sadly, we've got a lot of usage and
there's a lot of people adding the
recipes and now with uh us going close
to production, we're worried that it's
just not going to be able to handle the
load of all the people adding recipes
and interacting with the website. So, I
was tasked with
moving to a specialized library of um
that an external team developed so that
we can communicate more efficiently with
the database and things. um start
working properly. So we'll move away
from the previous one and start working
on that one.
So to start, one of the new uh things
that we've integrated into Visual Studio
nowadays is Gits of module support. Uh
that was something that um was one of
the main asked in that area. If you
click on the git menu manage branches,
you'll now see a submodules
uh tab there that you can where you can
see all the subm modules that you can
you have added and it will also tell you
uh with a warning icon if they are out
of date because things can happen in the
upstream. So we'll go ahead and add a
new one that contains the library that
we care about to support the new
connections.
Whoever wrote this task was kind enough
to give me all the inputs I need, which
is the name, how we'll identify the subm
module, where it lives,
and the location in our project
directory where it's going to live.
We'll add it. It'll take a little bit to
have time to refresh
and it should appear now. Cool. So, now
it's available. We have it locally and
now we just need to add a reference to
it.
Go to existing project. For some reason,
I'm outside of where this project is.
So, let's quickly go there.
So, this is the GitO module that I
downloaded. Here's the project.
And now I just need to tell my back end
to use it because of course we share the
same APIs. We have been talking about
this for a time. So let's just add the
project reference to the new project and
everything in theory should build and
work fine and we'll be extremely happy
with everything.
And let's see if it works.
Well, maybe it works. Uh, thankfully we
can debug. We're using Visual Studio.
So, let's see what's going on.
If you remember, one of the things that
we can do is attach to a process. For
that, we have the option to go to debug,
attach to process. That will open the
attach to process dialogue. Ctrl AltP
will also open it. We can look for the
site which is recipe. We can attach to
it. And now we can start um investigate
what's going on.
One of the things that we can do is just
test and see what type of input we're
getting into our
model. So let's go to the recipes
controller.
Let's get the recipe details. Setting a
break point and see what happens there.
I'll pick this one. We've hit the break
point. And now I can hover over recipe
and see that we're getting some
information here. That's correct.
But now some of the data is showing some
type of corruption. So I want to
investigate that further. Now there's a
lot of ways to investigate this. Number
one, we can use Copilot directly by
clicking this Copilot icon that appears
next to it. Or we can try to just
investigate ourselves beforehand.
This is the text visualizer. It appears
on all strings. That's a very old
feature. What we've added recently is
the ability to do certain decodings. So
probably we didn't decode. If we tried
that, doesn't work. So now I'm stuck. I
don't know what this is happening, why
this is happening. So let's ask copilot
to auto detect the format. This is
available through the string visualizer.
And now it has told me, hey, this is the
text. It is basically for encoded as I
thought, but there's an additional
compression through gip. Okay,
that clears more or less what I need to
do. Let's see what's happening in the
decoding function.
The other way I could do it is if I go
to
the string again through the data tip
and click analyze with copilot. As you
notice, I have already the chat window
open on the left side.
And you'll notice that it will change a
little bit once I click this button.
We'll cover what happened in a bit.
It'll start thinking.
It'll give me its analysis. It'll give
me a series. It'll start looking at the
code and it's going to take quite a
while. So if you're in a hurry, string
visualizer is much faster and much
better.
I check the Okay, so
let's go to
the recipe request. Probably this one.
Recipe pay.
Okay, so this is the decode method. We
can see that it is decompressing from
the well uh de
decoding from the B 64 string and then
it is reading the stream directly and
that's our problem. We're missing the
um viseralization.
If you remember from the previous talk
and for those that um are new, there's
something called code snippets. It's
something that I can add and quickly
code stuff that I do in a repetitive
version basis. So, because I do this all
the time and I'm preparing for this, I
already did part of it for this talk. I
can just double tap and there's a code
that was missing. Very easy for us to go
quickly through this code.
This is still working. I already did the
fix. So, we can just interrupt this. Or
it just finished. It told me the same
thing.
I can stop.
I can try again.
And now it's working. Very simple stuff
through that particular button.
Now the nice thing about this is this is
a long text. Well, that's interesting.
Let's see. I can again go to attach to
process dialogue and reattach. But if
you notice
there's the reattach shift LP is also a
mechanism. So because we have already
done that it will do so
unless it doesn't find it. Did I close
it?
Oh, it's there. I don't know what
happened there.
Okay, we attached.
I'm in the wrong VS that's why. Okay,
here we go.
Let's re reattach. Okay, now we're
there. And let's try again.
We stop at the break point. We can go
and investigate why the text is very
long. And you'll notice that I keep
doing this. It gets tiresome. So, I'll
just pin it.
Pin the ed tips are great because I can
just keep it here. It will
be stored in your user settings. So,
that thing will just stay constantly
every time you open the solution. And
the nice thing is that you can just keep
it there. You can keep stepping and
you'll be able to see it multiple times.
What many people don't know is that you
don't necessarily have to pin it to the
same source location. You can click the
pin icon again and that will cause it to
float on the screen location. So now it
always stays there.
Pin data tips also have some additional
features like comments. This will be
stored. So if you have very long uh
debugging sessions, you can start adding
comments just to remind yourself of what
you were doing there.
So
this is too long.
And that's save. You can keep it there
as a note. And
what you can also do is share them.
When we start setting break points,
which
we mentioned that you can export and
import them as an XML file that then
other people can use it so that someone
else more senior maybe can help someone
else debug something and give them
clues. Pinda tips also support that.
Sadly, this is a more hidden feature.
What you'll need to do is go to view
other windows
command window and you can access a
bunch of different commands more or less
the same things that you would access
through the UI through this window. So
in this case I can do debug dot export
data tips
and now I can save the data tip as let's
go here
data tips.
And now it's safe. It's great. I can
go ahead and unload it
and remove it.
It's gone. But then I can just go here
debug
import data tips
select the file
and it will appear and you have that um
in case it's useful.
So continuing with this investigation,
we have the description. It's super
long.
We can try and investigate why it's
super long. But the most important thing
is that going back to the text
visualizer, we've added somewhat
recently a new feature to search within
the visualizer for very long strings.
There's
it's not an obvious entry point
and it crashed.
That's new
live demos.
Okay, let's close this one.
This doesn't like me.
Oh, there we go.
Okay, let's go back.
Okay,
let's go here.
Let's go to a recipe.
Let's select the text visualizer. Okay.
Now to search just press Ctrl+ F and
you'll get the same experience as in the
editor. You can do um let's say history
and you can search for things forward
previous you can find all it will open a
new tool window where you can see
everything and
maybe you're interested in you can also
look at different uh scopes for your
search with all the different filters.
So that's something that's not that
obvious that you can do from there.
Cool. Any questions so far?
No. Awesome. Okay, let's move on. It
appears that things are ready.
People thought that we would run into
problems, so they decided to give us a
very useful uh unit test to make sure
that everything's ready before I just
say I'm done. So we can go to test
test explorer.
I see that there's my single test
because we are
always ready for this.
Am I debugging? Yep. Let's stop
debugging.
All right, let's run the test.
Cool. Everything passed. We are ready.
So that means that we have absolutely
everything. We can mark this as complete
and move on.
Now,
I was also tasked with investigating an
issue in the app where it appears to
hang. Now, we have a bunch of different
functionality for um handling this. I
can let the CLI handle it or I can let
VS do the work.
You can simply copy the
uh URL of the bug to the copilot chat
window and it will start doing the
investigation.
Now the important thing is that once I
do this as you've seen in many other
copilot demos, it will start doing what
the CLI would do. It's tag analysis.
It's trying to figure out based on the
description
what's going on. Now, of course, there's
cases in which this is useful, but in
this case, it's a particular hard bug.
It doesn't repro every time. So, it will
have a little bit of a hard time trying
to reproduce it.
So, instead of that, we can go into this
lower portions which shows different
available agents that we can use.
And for some reason, things are
I might need to log in again.
All right, let me close this and reopen.
Probably a crash.
Okay, let's start. Okay, things seem to
be nice now.
Cool. Okay, so as I mentioned, agent
preview will try to do the static
analysis, but there's a lot of different
ones. And in this case, we want to use
debugger because debugger will actually
be able to start analyzing the issue
using all of the different debugger
tools that uh we provided over the years
like
um stack frame during live debugging. It
will start saying break points. It will
start uh checking locals and the state
of the application as it happens.
failing to connect for some reason, but
that's okay.
Let's debug it.
The Reaper steps are essentially trying
to add a new recipe. It fails and
people don't know why. So, why don't we
try to do salad
nice? Well, that's nice.
Let's look for some salad image.
This is fine.
Let's add it here. Now ingredients.
Let's say
one over gene.
and one cup of couscous. It's a couscous
salad
and directions.
Okay, let's publish the recipe.
I need to remove this. Okay,
continue.
And it's stuck. It will not move from
there. As the hang explained,
I can go ahead and press the break all
that one will start.
Um,
we'll stop at where we're waiting and we
have this useful thread waiting banner
with analyze by copilot. Again, this
will trigger the chat window with the
debugger agent selected, which again
will use all of the different debugger
tools that we've added. And now it'll
start analyzing same break points and
doing whatever it needs.
If I tried to do this without uh BS, it
would have had a hard time because
there's absolutely um no code issue uh
per se. It is an input issue uh when
connecting to a database and it does
require um
going through and
uh inspecting the the data live which
the CLI would not be able to.
So while that is working,
we can take a look at the
side again.
Yes.
Mhm. Just that.
you can let it uh try to investigate by
um giving it um several instructions of
things to try and it will start trying
to debug and cause the issue to
reproduce.
Does that make sense?
So essentially um
it is live debugging. It kind of
requires your input. Um
but it is possible if you for example
have a dump uh with the exception. BS
can analyze with copilot those dumps
analyze those exceptions and try to look
at the input that was that triggered the
exception and it will correlate that
with the code to try and give you the
solution.
Correct. Yes. If if the input is in the
code that caused the exception, it
should be able to read it, find it, and
analyze it to give you uh an hypothesis
of what is happening.
Yeah. Um, it only has access to what's
uh in the program memory, in the process
memory.
So, it won't have access to logs, but it
will have access to everything um that
you would in Visual Studio.
So, if the clue is there, it will find
it.
Now, this is taking a little longer than
I expected.
There it goes. All right, it found the
deadlock.
It applies the fixes
going.
Cool. It finished. This is everything
that's required to fix it. I can say
sure go ahead
and as we showed in the previous talk we
can go through the git tooling to
publish the PR and um
get it reviewed, accepted, merged, and
we're done there. The nice thing is that
we can now have the CLI do that in the
background or we can have our agent do
it in the background. So we can just um
continue investigating other stuff.
Now it seems that we found the hang. It
seems that we have uh populated the
database now correctly. It seems that
the website is working fine. Now we can
just double check,
make sure that there's nothing extra
lurking around.
I can see the recipe ingredients
description. I can also see the steps,
though that doesn't seem right.
Steps also don't seem right.
Okay, it seems there's an issue with the
steps. So, that's something that also
needs to be investigated.
Again, let's just add a break point.
Same location.
Let's open the details.
Let's check the steps. There's 11 steps
here. I open the enumeral visualizer and
I'll notice that
the steps are in order. So it's
definitely not something with the
coding. It's not something with the
database. Things seem to be correct. One
of the things that we recently added
that's not very obvious for people who
know about the enumeral visualizer is
that now you have support for the same
data tips that I have been using during
this demo inside the enumeral
visualizer. So if you want to open a
second visualizer, for example, to
analyze a very long string because that
tends to be a problem, you can do so.
And you can also just quickly inspect
more complicated objects instead of
using the classic uh rightclick expand
column, hide columns to see the
different properties uh for a big
collection. So it's clear that this is
not an issue right now.
So let's ask Copilot to do it. We can
just go to agent now because this is not
debugging. It's something in the front
end probably and I can tell it.
There's a problem
with steps for recipe in
the front end.
Can you investigate
and send out a PR to fix it?
Hopefully, we're able to connect. I've
got some problems there with that. Um,
but again, same thing as if I was in the
CLI. I can just without the MBS tell
Copilot to do stuff for me
and it should have no issue figuring out
what's going on here.
Okay, found the issue.
Applying the fix.
It should send out the PR.
Now again here I could have told it to
use a different work tree or create a
new branch.
Now while that is working we can go to
uh do some other stuff. As I mentioned,
we had um some updates are coming in the
uh next insiders. Um one of the classic
things that happen is that you have
something in production, there is a
crash and you get a dump with a uh with
the exception happening and there's
absolutely nothing. I can do the debug
with native
and I just get this. There's no symbols.
It's optimized. there's no source code
and I just need to figure out what's
going on. I could click the analyze with
copilot and that would start using the
different tools that I mentioned are
available to analyze everything that it
can.
If you go
here below, you'll notice that there's
select tools and skills. If you click
that button, you'll notice that there's
a debugger dropdown with all the
available things that it can use to
investigate issues. One of the new
things that were added was the debugger
disassembly tool. Once you select that,
it will be able to start using
um
those new features to investigate to
read disassembly, to read registers, to
read um the actual process memory and
come up with a solution much faster. If
I let this one go on, it will be like I
don't know uh something happened. I
don't have access to the source. Please
provide me with something. If I click it
again to create a new one, this one will
have access to those tools that I added
because they go through sessions. And
now it will be able to start calling as
you see read registers, read disassembly
and tell me, hey, this is a classic
issue with pointers. It is not something
that's in the source code. Again, it's
something that was triggered by input
based on the stack pointers and all of
that different information.
There's every different agent has uh its
own set of tools and it's worth just
taking a time to investigate what's
available so that you can also enable
disable them uh based on your scenario
because that should improve a little bit
of performance and of course because it
has access to this specialized tools it
will make less calls it will be faster
and it will cost less in token usage
because it can get to the problem
faster.
Well, to history, I can see um the other
ones doing their job.
Now, this one did the analysis and
um
this is the original one that finished.
And it's like, well, there's a crash
stop frame. Nothing important. Nothing
interesting here.
The new one is much better at telling me
like
um
ner references
when they're confir object um
due to some internal state. So that
tells me like um that is input uh passed
uh to the hashing routine which the
other one couldn't tell me.
Now, this one's should be almost done
creating the pull request.
You'll be able to see it in a bit. In
the meantime, we can go to
the git manage branches section because
as we mentioned in the previous talk,
you can from VS without leaving the ID
create a pull request. Now, we have the
ability to review pull requests. Since
this has been created, there's nothing
here. But once this uh finishes, you'll
be able to see it here. And we'll be
able to enter um the pull request view.
As you've noticed during this talk,
there's a lot of things going on in my
screen. And one of the main complaints
that I've seen from people uh over time
is BS is so overcrowded with stuff that
it's very hard to do what I want to do,
which is look at code, investigate code.
There's full screen mode that works on
the editor. That's with uh shift alt
enter.
So very um quickly you can just go in
investigate what you do. Penda tips work
here. So you will be able to see them
otherwise uh you wouldn't be a able to
unless you had like the locals all those
windows. That's the nice thing about uh
data tips.
And to exit you just press the same one
and you're back at it.
While this is finishing, is are there
any other questions?
Shift alt enter.
Sorry.
Yes. The get subm modules. Yes.
The purpose is to um
be able to check out other repos within
the same repo without having to bring
all of those things to the codebase. So
you can keep them independent
uh from each other. Essentially, it will
create a a tracking
um file that you'll be able to see if
you look at the explorer that will be
committed and it will essentially say
this is a submodule. This is the folder
where it lives and where things are
downloaded. This is the last commit that
I have from that uh um branch. and the
git subm module window will tell you um
hey that repo got some changes you're
out of date do you want to import them
and you can say yes please fetch them
and now you're up to date without having
at all to modify your code so that will
be completely
um outside the working Okay.
Is slow sometimes. Okay.
Correct. It will not be part of your
solution. That's why I had to go and add
it to my project. Uh the demo was
created to think, okay, this is an an
eventual thing that we want to move to.
Let's have a shared API so that it can
just be swapped once I import this. So
if you have like another library that
you want to use um but you don't want to
have like it checked into your code um
you can use a a GitHub model for that
correct because I want the reference but
it's not um necessary. Sometimes it's
like a testing library like you don't
want it to be in your code but you want
to use it and you want everyone in your
team to be able to uh make use of it for
validation testing
um it could be a compliance stuff that
it could be a tool or an agent that
checks um that things are um working
that are secure. There's a lot of
possibilities with subm modules.
This is taking a while. Okay.
Might be for me to create the branch,
right? Let's do that because that is
taking a while.
So, why don't we go ahead
and go to
my project where I have this recipe
website,
but it's not here.
Here
we go.
Oh, okay. It send out something. Okay,
let's send out the pull request.
Here's a pull request. Okay, that was
faster. Let's interrupt you since you
failed me.
And
now if we go to manage branches,
I'll refresh.
And now I see assigned to me or my team
active. I see my PR.
Now I can actually see it um within
Visual Studio has a description. I can
leave comments um without having to link
them to a particular source file. I can
see the different commits if I click it.
Uh, I can move to that version. Also, if
I click the different files, I'll be
able to see the diff view. Sadly, this
one doesn't work um with full screen
mode. I have complained about that and
hopefully it'll be fixed soon. Um,
but you can just move it outside.
Make it full screen. You can leave
comments per line. You can leave
suggestions which are very simple things
that you can
act on.
>> Yes,
>> correct.
>> Hey, there's a link. So,
>> let's see if it works.
There it is.
Yeah. Um the important thing is that you
can complete it, you can merge it, uh
you can mark as draft and you can also
approve it. So I can say like this is
horrible waiting for author
and you'll notice it changed um in Azure
Dubs. It also works for GitHub.
Any questions so far?
Yes.
Yes, that one is available. You can just
uh download to a terminal. Um
yes, sorry. So the question was
um how am I able to create the pull
request from the copilot chat window uh
without having
anything extra and the answer is I did
have to add the Azure CLI locally and
then copilot will use the PowerShell
which you notice the window opened in my
VS if I close this one
guard here and that's where it started
actually communicating with the Ashure
CLI there are MCP servers agent does
support it
and I have the Ashure Dubs MCP server
with all the tools that lets me get work
items, lets me get um pull requests,
builds and that sort of thing. Sadly, I
didn't uh I wasn't able to get it to
work. I need to investigate what uh
happened there, but it is something
that's definitely supported. Um
yeah, that's how you start letting BS do
other interactions uh through the chat
window with other tools and services.
Yeah, that's everything I had.
If you have any other questions, let me
know.
Let it here for a little while. Yes.
Yes.
>> Yeah. So the question was if you can
integrate this with git pull request and
see them uh in BS.
>> Yeah. So uh for that if you'll notice
here there's repositories there's a
bunch of other ones. uh this is the one
that I demoed but
you can have other uh Azure DevOps repos
and al also GitHub repos and they will
show here if they're in their directory
you can switch to them and that uh PR
view will populate and it will show you
active pull requests that you haven't
checked out and you'll be able to see
them and um review them from there.
>> Oh yes. So, uh, if we go back to the,
um,
pull request that I had,
there should be uh,
just
Is it here? Oh, yeah. Is it here?
There is a way to do it, but I don't
remember where.
Sorry.
>> If only
>> Oh, only the pending changes view. Okay.
Yes.
>> Yep.
Is it here?
Interesting.
There is an option but I can't find it
right now.
But you can also use the get um agent
and that will do that review for you.