Forum Discussion
Localhost refused to connect in the hello world demo
I am working on a school project which is developing a Microsoft Teams web app. I followed the instructions given in the https://docs.microsoft.com/en-us/microsoftteams/platform/build-your-first-app/build-and-run to create a hello world demo. But when I run the project in VS code I met these error messages:
2020-11-28T15:25:39.764Z AppCache: App Cache is not defined on the desktop app
statics.teams.cdn.office.net/hashedjs/0-angular-jquery.min-eee9041.js:114
2020-11-28T15:25:39.810Z transportDependencyProviderService: transport can't be initialized, settingsService is enabled - true,
desktop is pluginless - false,
destop is Hwa - true,
is desktop client - false,
slimcore enabled - false
Error: Failed to resolve: the task is already resolved
at o._checkState (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5680141)
at o.resolve (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5678949)
at Object.successFunc (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5895803)
at https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5681654
at a (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5675968)
at o._resolveCallback (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5681633)
at https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5681525
at Array.forEach (<anonymous>)
at o._resolveSuccesses (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5681443)
at o._addCallbackSet (https://statics.teams.cdn.office.net/hashedjs/3.1-app.min-5d09005.js:1:5677955) Unhandled error caught in promise chainI also put the screenshots of the errors here as it might be easier to read with all the informations:
I have been able to add it into teams, but it displays "localhost refused to connect" under the "Personal Tab"; and no response returned from the chatbot.
The `localhost:3978` displays Cannot GET /.
I am sure that the `nvm install` and `nvm start` has run successfully.
The whole project is generated by VS Code Microsoft Teams toolkit. Is is the problem of my network? Do I need to modify any settings for this project? Can some one tell me how should debug this problem? Thanks!!!
7 Replies
- Mallipriya_MSFTFormer Employeechaozy, Could you please confirm sideloading for custom apps is enabled in teams admin center?
- chaozyCopper Contributor
Mallipriya_MSFT Sorry to reply so late. Yes I have enabled that option when I saw something like "require permission to add the app", and I have been able to add it into my Teams. The case now is that it says "localhost refused to to connect" under the tab named "Personal tab". From the tutorial I should expect a welcome page from there. Also the chatbot does not reply anything. I will keep trying to explore it.
Thanks to your reply!
- Manish-MSFTFormer Employee
chaozy , Are you behind any firewall, since bot framework requires a un-restricted access to internet, please contact your IT-admin for unblocking the endpoint and allowing bot framework emulator.
- chaozyCopper Contributor
Manish-MSFT Sorry to reply so late. I have checked my firewall settings and the Bot framework emulator has been set to "allow incoming connections". It is my personal computer with home network, and the account I used to sideload the app is my personal Microsoft 365 developer account, so I think I have the access to my unblock anything. Could you please give me some suggestions about what else should be enabled? I can immediately check that.
Thanks to your reply!!- Manish-MSFTFormer Employee
chaozy , Could you please mail me at v-manisc@microsoft.com to get on call and solve this issue. Thanks.