microsoft / botbuilder-js

Welcome to the Bot Framework SDK for JavaScript repository, which is the home for the libraries and packages that enable developers to build sophisticated bot applications using JavaScript.
https://github.com/Microsoft/botframework
MIT License
679 stars 276 forks source link

Getting type definition error post update of botbuilder to 4.15.0 #4010

Closed sanjeev9160 closed 2 years ago

sanjeev9160 commented 2 years ago

Github issues should be used for bugs and feature requests. Use Stack Overflow for general "how-to" questions.

Versions

What package version of the SDK are you using: version 4.15.0 What nodejs version are you using: v14.15.0 What browser version are you using What os are you using: macOS Catalina, version 10.15.7

Describe the bug

Our project has a dependency on the botbuilder library, earlier version is "botbuilder": "^4.7.2". Now I have updated the botbuilder to 4.15.0 i.e. The dependency is "botbuilder": "^4.15.0".

Post updating the botbuilder and building the solution, I am getting the type definition error compile error. node_modules/botbuilder-core/lib/configurationBotFrameworkAuthentication.d.ts:50:227 - error TS2304: Cannot find name 'RequestInfo'. node_modules/botbuilder-core/lib/configurationBotFrameworkAuthentication.d.ts:50:247 - error TS2304: Cannot find name 'RequestInit'. node_modules/botbuilder-core/lib/configurationBotFrameworkAuthentication.d.ts:50:271 - error TS2304: Cannot find name 'Response'. node_modules/botframework-connector/lib/auth/botFrameworkAuthenticationFactory.d.ts:32:435 - error TS2304: Cannot find name 'RequestInfo'. node_modules/botframework-connector/lib/auth/botFrameworkAuthenticationFactory.d.ts:32:455 - error TS2304: Cannot find name 'RequestInit'. node_modules/botframework-connector/lib/auth/botFrameworkAuthenticationFactory.d.ts:32:479 - error TS2304: Cannot find name 'Response'.

To Reproduce

  1. Create any node project and add the dependency of botbuilder 4.15.0 into the package.json
  2. Build the solution.

Expected behavior

No compile error should have come.

Screenshots

image

Additional context

Add any other context about the problem here.

joshgummersall commented 2 years ago

Those are fetch types, so please include "dom" in your tsconfig.json "lib" array.