Skip to content

[🐛 Bug]: including webdriverio as a ts dep generates a build error regarding puppeteer-core #10726

@jlipps

Description

@jlipps

Have you read the Contributing Guidelines on issues?

WebdriverIO Version

8.12.1

Node.js Version

18.15.0

Mode

Standalone Mode

Which capabilities are you using?

not relevant

What happened?

Trying to compile my TS based project which uses WDIO as a dependency, and getting stuck on this error:

node_modules/puppeteer-core/lib/esm/puppeteer/common/Debug.d.ts:22:62 - error TS7016: Could not find a declaration file for module 'debug'. '/Users/jlipps/Code/gh/jlipps/appium-ocr-plugin/node_modules/puppeteer-core/node_modules/debug/src/index.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/debug` if it exists or add a new declaration (.d.ts) file containing `declare module 'debug';`

22 export declare function importDebug(): Promise<typeof import('debug')>;

I'm not using puppeteer-core at all. It appears to be imported by WDIO.

What is your expected behavior?

No WDIO-related TS build issues

How to reproduce the bug.

Try to build this project at this branch: https://github.com/jlipps/appium-ocr-plugin/tree/jlipps/updates

Relevant log output

n/a

Code of Conduct

  • I agree to follow this project's Code of Conduct

Is there an existing issue for this?

  • I have searched the existing issues

Metadata

Metadata

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions