I am stuck due to this error. I have downgraded from Enterprise to Pro version of Visual Studio 2022 then this error came in. I have tried numerous times repairing, uninstalling, reinstalling, and nothing worked.
I created a new console app then added Docker support, that is it. As soon as I add container support I get a message in the output window, which is as follows:
========== Checking for Container Prerequisites ==========
Verifying that Docker Desktop is installed...
Docker Desktop is installed.
========== Verifying that Docker Desktop is running... ==========
Verifying that Docker Desktop is running...
A non-critical error occurred while getting the containers ready. Your projects will continue to function normally. The error was: Illegal characters in path.
And this is the error when I hit debug button this error occurs.
The "ContainerBuildAndLaunch" task failed unexpectedly.
System.ArgumentException: Illegal characters in path.
at System.IO.Path.CheckInvalidPathChars(String path, Boolean checkAdditional)
at System.IO.Path.Combine(String path1, String path2)
at Microsoft.VisualStudio.Containers.Tools.Common.PathUtilities.FindFullCommandPathFromPathVariable(String command, String[] extensions)
at Microsoft.VisualStudio.Containers.Tools.Common.Client.DockerClient.FindFullDockerCommandPath()
at Microsoft.VisualStudio.Containers.Tools.Common.Prerequisites.DockerForWindowsRunningPrerequisite.<IsDockerFunctioningAsync>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Containers.Tools.Common.Prerequisites.DockerForWindowsRunningPrerequisite.<EvaluateAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Microsoft.VisualStudio.Containers.Tools.Common.Prerequisites.CompositePrerequisite.<EvaluateAsync>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Containers.Tools.Shared.ContainerLaunchPrerequisiteTaskUtilities.<EvaluateBuildPrerequisitesAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Containers.Tools.Tasks.ContainerBuildTask.<ExecuteAsync>d__30.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Containers.Tools.Tasks.ContainerBuildTask.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__26.MoveNext()
1 Answer 1
now I return here to share what i have found on this problem. You cant believe it but it was due to some missing packages and I found it while comparing my installed packages with a colleague.
Error description btw was really poor and led us to really different areas to look for a solution.
So dropping here a screenshot of what packages I choosed while installing. After those installed , all came back and worked like a charm. :)
asp.net and web development
azure development
python development
node.js development
.net multi-platform app ui development
winui application development
.net desktop development
mobile development with c++
desktop development with c++
Comments
Explore related questions
See similar questions with these tags.
FindFullCommandPathFromPathVariable. Based on the name it seems to look for your Docker exectuable in thePATHenvironment variable. Carefully check the contents of both your machine-wide and your user-specificPATHvariable and see if there are any invalid characters (screenshot - check both under User variables and System variables)