Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot create new Teams apps with Teams Toolkit in Visual Studio Community 17.10.2 #11834

Open
adr15 opened this issue Jun 16, 2024 · 7 comments
Assignees
Labels
TA:E2E Team Area: E2E

Comments

@adr15
Copy link

adr15 commented Jun 16, 2024

When trying to create a new Teams app using Teams Toolkit in Visual Studio, I'm always getting a message "The system cannot find the path specified. (Exception from HRESULT: 0x80070003)". The project is created but incomplete.

I've encountered this issue after updating the last version of VS (17.10.2) - but not sure this is the issue.
I've reinstalled VS and the operating system, the behavior is the same.

I've installed same VS Community 17.10.2 with Microsoft Teams development tools options from scratch on a new computer - the same behavior.

Until some weeks ago I've used Teams Toolkit with no issues.

In VS log the full record is:

3081 2024/06/15 20:43:19.971 Error Template provider aggregator System.IO.DirectoryNotFoundException: The system cannot find the path specified. (Exception from HRESULT: 0x80070003) at Microsoft.VisualStudio.CommonIDE.Solutions.Interop.IVsNativeEnvironmentInternal.WizLoadAndRunFile(String pwszWizard, String pwszDestination, Boolean bCloseSolution, Boolean bRunSilent, Array psaCustomParams, String pwszFrameworkVersion) at Microsoft.VisualStudio.CommonIDE.Solutions.Dte.DteSolution.<AddFromTemplateExAsync>d__248.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.VisualStudio.CommonIDE.Solutions.Dte.DteSolution.<AddFromTemplateExAsync>d__248.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.VisualStudio.CommonIDE.Solutions.Dte.DteSolution.<AddFromTemplateExAsync>d__248.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.Threading.JoinableTask.CompleteOnCurrentThread() at Microsoft.VisualStudio.Threading.JoinableTask`1.CompleteOnCurrentThread() at Microsoft.VisualStudio.CommonIDE.Solutions.Dte.DteSolution.AddFromTemplateEx(String FileName, String Destination, String ProjectName, String SolutionName, Boolean Exclusive, UInt32 Options) at Microsoft.VisualStudio.CommonIDE.Solutions.Dte.DteSolution.<>c__DisplayClass25_0.<EnvDTE100.Solution4.AddFromTemplateEx>b__0() at Microsoft.VisualStudio.NewProjectDialog.LegacyVsTemplateProvider.GetInstantiationResult(CreateProjectResult result) at Microsoft.VisualStudio.NewProjectDialog.LegacyProjectTemplateProvider.<InstantiateTemplateAsync>d__10.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.TemplateProviders.TemplateProviderSupport.ExceptionLoggingTemplateProviderDecorator.<InstantiateTemplateAsync>d__9.MoveNext() 3082 2024/06/15 20:43:20.172 Error SccDisplayInformation.SolutionOptions Unable to load solution user option 'SccProvider.Solution.LoadCount' 3083 2024/06/15 20:43:20.176 Error SccDisplayInformation.SolutionOptions Unable to load solution user option 'SccProvider.Solution.LastBranch'
@microsoft-github-policy-service microsoft-github-policy-service bot added the needs attention This issue needs the attention of a contributor. label Jun 16, 2024
@adashen adashen added investigating TA:Auth Team Area: Auth labels Jun 17, 2024
@Alive-Fish
Copy link
Contributor

Hi @adr15, thanks for reporting. Could you provide more information about the following questions?

  1. Do you try to create other templates, such as a console app?
  2. What template of Teams do you try to create?
  3. Can you run the commands on the older project?

@Alive-Fish Alive-Fish added needs more info Need user to provide more info and removed investigating labels Jun 17, 2024
@blackchoey blackchoey assigned Alive-Fish and unassigned blackchoey Jun 17, 2024
@blackchoey blackchoey added TA:E2E Team Area: E2E and removed TA:Auth Team Area: Auth labels Jun 17, 2024
@adr15
Copy link
Author

adr15 commented Jun 17, 2024

Hi @adr15, thanks for reporting. Could you provide more information about the following questions?

  1. Do you try to create other templates, such as a console app?
  2. What template of Teams do you try to create?
  3. Can you run the commands on the older project?

1 - any other template works, except the ones created with Teams Toolkit
2- Echo and AI ChatBot
3 - Yes, if I open old projects they work with no problems

@microsoft-github-policy-service microsoft-github-policy-service bot removed the needs more info Need user to provide more info label Jun 17, 2024
@Alive-Fish
Copy link
Contributor

Alive-Fish commented Jun 18, 2024

Thank you. Can you check if there is a folder Microsoft.TeamsFx.Sdk under %VS_Installer_Path%/MSBuild/Sdks and there are some files under Microsoft.TeamsFx.Sdk/Sdk? Seem like:

image

By the way, where do you find the VS logs? I hope to reproduce the issue and see the log.

@adashen adashen added investigating needs more info Need user to provide more info and removed needs attention This issue needs the attention of a contributor. labels Jun 18, 2024
@adr15
Copy link
Author

adr15 commented Jun 19, 2024

Thank you. Can you check if there is a folder Microsoft.TeamsFx.Sdk under %VS_Installer_Path%/MSBuild/Sdks and there are some files under Microsoft.TeamsFx.Sdk/Sdk? Seem like:

image

By the way, where do you find the VS logs? I hope to reproduce the issue and see the log.

Yes, I have the folder and and the files.

I'll try later to generate another log file and get back with location deleted the other file and don't remember were it was

@microsoft-github-policy-service microsoft-github-policy-service bot added needs attention This issue needs the attention of a contributor. and removed needs more info Need user to provide more info labels Jun 19, 2024
@Alive-Fish
Copy link
Contributor

That's strange. I am not sure why it happened on your machine, but there is an environment that can control the template content. You can try to set system environment TEAMSFX_NEW_PROJECT_TYPE to false and try to create a new Teams App project again. Remember you need close the Visual Studio installer and Visual Studio instance after changing the environment.

Hope it can help you. Thanks!

@adashen adashen added needs more info Need user to provide more info and removed needs attention This issue needs the attention of a contributor. labels Jun 24, 2024
@davidclinger
Copy link

I had the same error message resulting in an incompletely created new project working in 17.10.3. I was able to work around it by running VS as administrator.

@microsoft-github-policy-service microsoft-github-policy-service bot added needs attention This issue needs the attention of a contributor. and removed needs more info Need user to provide more info labels Jun 25, 2024
@Alive-Fish
Copy link
Contributor

Thank you @davidclinger.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TA:E2E Team Area: E2E
Projects
None yet
Development

No branches or pull requests

5 participants