Backoffice getting black overlay in Hot Reload, when uda files change

When running a project locally with hot reload (dotnet watch), every time I do something, that updates a uda file (Umbraco Deploy), the backoffice gets a black overlay like this:

<div id="dotnet-compile-error" style="z-index:1000000; position:fixed; top: 0; left: 0; right: 0; bottom: 0; background-color: rgba(0,0,0,0.5); color:black; overflow: scroll;"></div>

I can see these messages in my terminal:

dotnet watch ⌚ File updated: .\umbraco\Deploy\Revision\document-type__2d4cae556d234718b91b340d75220a22.uda
dotnet watch ⌚ No C# changes to apply.

Anyone know how I can prevent that, while still running with hot reload?

Is this v17?

Yup - was missing a v17 tag when creating the post :wink:

It was right there all this time.. :wink:

First off, I never liked hot reload and I don’t trust it.. but that’s just my personal opinion!

But it looks like it MIGHT be fixed in an upcoming .NET release https://github.com/dotnet/sdk/issues/51825 - though not entirely sure this is the exact issue.

I think for now you could just ignore that folder, in your .csproj:

<ItemGroup>
  <Watch Remove="umbraco\Deploy\**\*.*" />
</ItemGroup>

Cool, I’ll wait for the .net update then :slight_smile:

By the way - can we make the v17 tag more obvious? :wink:

I tried that and it didn’t work. I think it’s because the files aren’t there at build time (I think Deploy deletes the files, then creates them)

So I googled a bit, and found I could put them in DefaultItemExcludes like this:


	<PropertyGroup>
		<DefaultItemExcludes>$(DefaultItemExcludes);umbraco\Deploy\**\*.*</DefaultItemExcludes>
	</PropertyGroup>

This works :slight_smile:

It’s sorted by most used.. it will float to the top eventually.

I don’t think you should wait though, it doesn’t seem ENTIRELY related. Also, you really don’t need watchers on that folder, we should probably add a default ignore for some folders in the umbraco directory.

Ooh nice one! Wonder what else should be in a default ignore..

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.