question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

System.IO.IOException

See original GitHub issue

I am sporadically getting the following errors

Severity	Code	Description	Line	File	Project	Suppression State	Tool
Error		Unhandled exception: System.IO.FileNotFoundException: Could not find file 'obj\Debug\net472\SimControl.Templates.CSharp.ConsoleApp.exe'.
File name: 'obj\Debug\net472\SimControl.Templates.CSharp.ConsoleApp.exe'
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite, Boolean checkHost)
at System.IO.File.Copy(String sourceFileName, String destFileName, Boolean overwrite)
at StitcherBoy.Reflection.ModuleManager.LoadWithTemp(String assemblyPath, Nullable`1 useTemp)
at StitcherBoy.Weaving.Build.AssemblyStitcher.LoadModule(String assemblyPath)
at StitcherBoy.Weaving.Build.AssemblyStitcher.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAssemblyPath)
at StitcherBoy.Weaving.StitcherProcessor.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAsemblyPath)
at StitcherBoy.Weaving.StitcherProcessor.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAsemblyPath)
at StitcherTask`1.Run(Boolean fromExe)	10	C:\Users\WilhelmMedetz\.nuget\packages\mradvice\2.8.8\build\MrAdvice.targets	SimControl.Templates.CSharp.ConsoleApp		MrAdviceTask


Error		Unhandled exception: System.IO.IOException: Der Vorgang ist bei einer Datei mit einem geöffneten Bereich, der einem Benutzer zugeordnet ist, nicht anwendbar.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite, Boolean checkHost)
at System.IO.File.Copy(String sourceFileName, String destFileName, Boolean overwrite)
at StitcherBoy.Reflection.ModuleManager.LoadWithTemp(String assemblyPath, Nullable`1 useTemp)
at StitcherBoy.Weaving.Build.AssemblyStitcher.LoadModule(String assemblyPath)
at StitcherBoy.Weaving.Build.AssemblyStitcher.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAssemblyPath)
at StitcherBoy.Weaving.StitcherProcessor.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAsemblyPath)
at StitcherBoy.Weaving.StitcherProcessor.Process(StringDictionary parameters, Guid buildID, DateTime buildTime, String entryAsemblyPath)
at StitcherTask`1.Run(Boolean fromExe)	10	C:\Users\WilhelmMedetz\.nuget\packages\mradvice\2.8.8\build\MrAdvice.targets	SimControl.Templates.CSharp.ConsoleApp		MrAdviceTask

The underlying system error seems to be ERROR_USER_MAPPED_FILE. After starting another build the build usually succeeds (but the errors remain in the error window).

I will try to provide more detailed information.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
wilhelmmedetzcommented, Dec 29, 2020

2.8.12 seems to fix this this issue

1reaction
wilhelmmedetzcommented, Jun 22, 2020

I ONLY use the new SDK style projects (mostly with multitarget configurations).

Read more comments on GitHub >

github_iconTop Results From Across the Web

IOException Class (System.IO)
IOException is the base class for exceptions thrown while accessing information using streams, files and directories. The Base Class Library includes the ...
Read more >
c# - System.IO.IOException: file used by another process
System.IO.IOException: The process cannot access the file 'E:\mypath\myFile.cs' because it is being used by another process. at System.IO.
Read more >
C# IOException - working with I/O errors in C#
NET throws IO exceptions when an IO error happens. The base IO exception is called IOException . There are several other more specific...
Read more >
system.io.ioexception: 'the process cannot access the file ' ...
How do I solve this issue: system.io.ioexception: 'the process cannot access the file '@.txt' because it is being used by another process.'.
Read more >
System.IO.IOException that does...nothing?
I have a C# program that makes HTTP requests to a server via HttpClient. Said HttpClient is a static object used by every...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found