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

Configuring Teams app failed #5104

Closed
Diman96 opened this issue May 20, 2022 · 15 comments
Closed

Configuring Teams app failed #5104

Diman96 opened this issue May 20, 2022 · 15 comments
Assignees
Labels
investigating needs more info Need user to provide more info TA:VS Team Area: Visual studio

Comments

@Diman96
Copy link

Diman96 commented May 20, 2022

When I try to create an application like it says in the tutorial (https://docs.microsoft.com/en/microsoftteams/platform/sbs-gs-blazorupdate?tabs=vs). In step 1 Select Project > Teams Toolkit > Configure Your Microsoft Teams.(https://docs.microsoft.com/en-us/microsoftteams/platform/sbs-gs-blazorupdate?tabs=vs&tutorial-step=3)
image

I get an error like this
image

And output

[core] success to acquire lock for task localDebugV2  on: C:\Users\Admin\source\repos\MyTeamsApp1\MyTeamsApp1\.fx
[core] success to get questions for localDebugV2
Running fx-resource-frontend-hosting concurrently
Running fx-resource-aad-app-for-teams concurrently
[AAD App Registration] Start to local debug
Running fx-resource-local-debug concurrently
The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters.  Detailed error: The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters. .
[Teams Toolkit] Execute Task summary----------------------------
fx-resource-frontend-hosting-provisionLocalResource......... [ok]
fx-resource-aad-app-for-teams-provisionLocalResource........ [failed]
fx-resource-local-debug-provisionLocalResource.............. [ok]
[Teams Toolkit] Task overall result.........................[failed]
[core] persist local settings config file: C:\Users\Admin\source\repos\MyTeamsApp1\MyTeamsApp1/.fx/configs/localSettings.json
[core] persist project setting file: C:\Users\Admin\source\repos\MyTeamsApp1\MyTeamsApp1\.fx\configs\projectSettings.json
[core] lock released on C:\Users\Admin\source\repos\MyTeamsApp1\MyTeamsApp1\.fx
[core] finish task:localDebugV2 , time: 275 ms
{
  "errorType": "SystemError",
  "source": "Fx-VS",
  "name": "UnknownError",
  "message": "The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters. ",
  "stack": "   at System.Convert.FromBase64_Decode(Char* startInputPtr, Int32 inputLength, Byte* startDestPtr, Int32 destLength)\r\n   at System.Convert.FromBase64CharPtr(Char* inputPtr, Int32 inputLength)\r\n   at System.Convert.FromBase64String(String s)\r\n   at TeamsFx.VisualStudio.Commonlib.LoginUtils.DecodeToken(String token)\r\n   at TeamsFx.VisualStudio.RPC.Target.AppStudioTarget.<GetAccountInfoAsync>d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.Debug.<ExecuteAsync>d__16.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.TeamsFxOleMenuCommand.<<InvokeHandler>b__23_1>d.MoveNext()",
  "innerError": null,
  "userData": null,
  "timestamp": "2022-05-20T14:50:16.2283166+03:00",
  "displayMessage": null,
  "helpLink": null,
  "issueLink": null
}

I try on Visual Studio Professional 2022 v17.2.1 and Visual Studio Enterprise 2022 Preview v17.3.0 preview 1.0

@ghost
Copy link

ghost commented May 20, 2022

Thank you for contacting us! Any issue or feedback from you is quite important to us. We will do our best to fully respond to your issue as soon as possible. Sometimes additional investigations may be needed, we will usually get back to you within 2 days by adding comments to this issue. Please stay tuned.

@Diman96
Copy link
Author

Diman96 commented May 25, 2022

Any updates?

@ghost ghost added the needs attention This issue needs the attention of a contributor. label May 25, 2022
@JerryYangKai
Copy link
Contributor

JerryYangKai commented May 26, 2022

@Diman96 Thanks for reporting this issue, also this log is very helpful, I will take a look at it with my teammates.

@JerryYangKai
Copy link
Contributor

JerryYangKai commented May 27, 2022

@Diman96 Is this still blocking your local debug? Could you please log out and re-signin your account and try again.

@Diman96
Copy link
Author

Diman96 commented May 27, 2022

@JerryYangKai I logged out of my VS account and logged back in. This did not help, the error is the same. I also logged out of my account and the teams toolkit window prompted me to log in to my account and it didn't help the error remained the same.

Безымянный

The output started to look like this:

[core] start task:localDebugV2 , API v3: false
[core] success to acquire lock for task localDebugV2  on: C:\Users\Admin\source\repos\Web\3DL.Teams\.fx
[core] success to get questions for localDebugV2
[core] lock released on C:\Users\Admin\source\repos\Web\3DL.Teams\.fx
{
  "errorType": "SystemError",
  "source": "Fx-VS",
  "name": "UnknownError",
  "message": "The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters. ",
  "stack": "   at System.Convert.FromBase64_Decode(Char* startInputPtr, Int32 inputLength, Byte* startDestPtr, Int32 destLength)\r\n   at System.Convert.FromBase64CharPtr(Char* inputPtr, Int32 inputLength)\r\n   at System.Convert.FromBase64String(String s)\r\n   at TeamsFx.VisualStudio.Commonlib.LoginUtils.DecodeToken(String token)\r\n   at TeamsFx.VisualStudio.RPC.Target.AppStudioTarget.<GetAccountInfoAsync>d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.Debug.<ExecuteAsync>d__16.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.TeamsFxOleMenuCommand.<<InvokeHandler>b__23_1>d.MoveNext()",
  "innerError": null,
  "userData": null,
  "timestamp": "2022-05-27T11:38:42.4660417+03:00",
  "displayMessage": null,
  "helpLink": null,
  "issueLink": null
}

@JerryYangKai
Copy link
Contributor

Add @xiaolang124 , could you please help figuring out whether the log in is blocking, thanks.

@xiaolang124
Copy link
Contributor

Sorry for you inconvenience. What account do you use for Configurate Teams app, is it personal account? If yes, please change it to a work account, and try again. If not, can you try to create a free Teams developer tenant and try again? We will investigate more on this problem.

@Diman96
Copy link
Author

Diman96 commented May 30, 2022

@xiaolang124
Before that, I used my work account.

When I created free Teams developer tenant and log in with this account in Visual Studio. I try Configure Microsoft Teams app again, my output starts look like this:

[core] start task:localDebugV2 , API v3: false
[core] success to acquire lock for task localDebugV2  on: C:\Users\Admin\source\repos\MyTeamsApp3\MyTeamsApp3\.fx
[core] success to get questions for localDebugV2
Running fx-resource-frontend-hosting concurrently
Running fx-resource-aad-app-for-teams concurrently
[AAD App Registration] Start to local debug
Running fx-resource-local-debug concurrently
[AAD App Registration] Successfully parsed permissions.
[AAD App Registration] Successfully created Azure AD app.
[AAD App Registration] Successfully created password for Azure AD app.
[AAD App Registration] Successfully updated permission for Azure AD app.
[AAD App Registration] Successfully local debug
[Teams Toolkit] Execute Task summary----------------------------
fx-resource-frontend-hosting-provisionLocalResource......... [ok]
fx-resource-aad-app-for-teams-provisionLocalResource........ [ok]
fx-resource-local-debug-provisionLocalResource.............. [ok]
[Teams Toolkit] Task overall result.........................[ok]
[AAD App Registration] Successfully created application id uri for Azure AD app.
[core] lock released on C:\Users\Admin\source\repos\MyTeamsApp3\MyTeamsApp3\.fx
{
  "errorType": "SystemError",
  "source": "Fx-VS",
  "name": "UnknownError",
  "message": "The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters. ",
  "stack": "   at System.Convert.FromBase64_Decode(Char* startInputPtr, Int32 inputLength, Byte* startDestPtr, Int32 destLength)\r\n   at System.Convert.FromBase64CharPtr(Char* inputPtr, Int32 inputLength)\r\n   at System.Convert.FromBase64String(String s)\r\n   at TeamsFx.VisualStudio.Commonlib.LoginUtils.DecodeToken(String token)\r\n   at TeamsFx.VisualStudio.RPC.Target.AppStudioTarget.<GetAccountInfoAsync>d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.Debug.<ExecuteAsync>d__16.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at TeamsFx.VisualStudio.Commands.TeamsFxOleMenuCommand.<<InvokeHandler>b__23_1>d.MoveNext()",
  "innerError": null,
  "userData": null,
  "timestamp": "2022-05-30T11:04:35.6702747+03:00",
  "displayMessage": null,
  "helpLink": null,
  "issueLink": null
}

@xiaolang124
Copy link
Contributor

xiaolang124 commented May 31, 2022

It may be caused by our toolkit encoding compatibility issue. What language do you use for your system and what encode type do you normally use? Or what is your VS default encode type?

@Diman96
Copy link
Author

Diman96 commented May 31, 2022

@xiaolang124 Visual Studio in english, OS in russian, but I changed it to english and it did not help, connected such language packs for keyboard as russian, ukrainian and english.
image

What exactly do you mean by the "encode type"? In Windows should use the standard encoding utf-16 if I'm not mistaken, but where to see it and check, I don't know.

@therealjohn therealjohn added the TA:VS Team Area: Visual studio label May 31, 2022
@xiaolang124
Copy link
Contributor

xiaolang124 commented Jun 1, 2022

I have reproduced this problem by this step. It may be the same reason that caused the issue. I created an account with the name João, and I tried to log in and Configure Microsoft Teams app. Then the toolkit will pop up this error.
For the short term, you can create an account in your free Teams developer tenant with pure letters and try again.
For the long term, we will fix this problem and support this scenario.
Thanks for reporting this.

@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 6, 2022
@eriolchan eriolchan removed the TA:Compute Team Area: Compute label Jun 12, 2022
@ghost ghost added the no recent activity The issue labeled needs more info gets no reply from issue owner in time label Jun 19, 2022
@ghost
Copy link

ghost commented Jun 19, 2022

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 7 days. It will be closed if no further activity occurs within 3 days of this comment. If it is closed, feel free to comment when you are able to provide the additional information and we will re-investigate.

@ghost
Copy link

ghost commented Jun 22, 2022

Due to lack of details for further investigation, we will archive the issue for now. In case you still have following-up questions on this issue, please always feel free to reopen the issue by clicking ‘reopen issue’ button below the comment box. We will get back to you as soon as possible.

@ghost ghost closed this as completed Jun 22, 2022
@dima1131
Copy link

Hi all, at the moment 2023-06-30 the problem persist.
{
"errorType": "SystemError",
"source": "Fx-VS",
"name": "CannotConnectServerError",
"message": "The operation has timed out.",
"stack": " at Microsoft.VisualStudio.Threading.TplExtensions.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at TeamsFx.VisualStudio.RPC.Client.d__11.MoveNext()",
"innerError": null,
"userData": null,
"timestamp": "2023-06-30T17:11:49.438493+02:00",
"displayMessage": null,
"helpLink": null,
"issueLink": null
}

Do someone resolved this issue?
Also i cannot create an empty project. I have this error.
immagine (1)

image

@ghost ghost removed the no recent activity The issue labeled needs more info gets no reply from issue owner in time label Jun 30, 2023
@mjoksa
Copy link

mjoksa commented Jun 3, 2024

Hi all, at the moment 2023-06-30 the problem persist. { "errorType": "SystemError", "source": "Fx-VS", "name": "CannotConnectServerError", "message": "The operation has timed out.", "stack": " at Microsoft.VisualStudio.Threading.TplExtensions.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at TeamsFx.VisualStudio.RPC.Client.d__11.MoveNext()", "innerError": null, "userData": null, "timestamp": "2023-06-30T17:11:49.438493+02:00", "displayMessage": null, "helpLink": null, "issueLink": null }

Do someone resolved this issue? Also i cannot create an empty project. I have this error. immagine (1)

image

I experience same issue with the latest Visual Studio Community (17.11.0. Preview 1.1).
Cannot debug in Visual Studio anymore, and for that matter, cannot even start my bot locally.
Ant solution for this?

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigating needs more info Need user to provide more info TA:VS Team Area: Visual studio
Projects
None yet
Development

No branches or pull requests

8 participants