-
Notifications
You must be signed in to change notification settings - Fork 32
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
Namespace 'global.WebDriver' has no exported member 'Client' after updating WDIO to v7 #229
Comments
PRs welcomed. As you have experienced, I don't believe this is currently done correctly. @christian-bromann is best positioned to offer insight on how services that add custom commands can provide accurate types for all WDIO versions that have official support. Until then, you will probably need to modify the types yourself locally. IIRC there are other issues in this repo that have identified issues with this library and typescript. |
@tehhowch I don't feel I really understand this anywhere near well enough to contribute, but making the following change at line 60 of
After making the change, intercept service also seemed to be working normally in all configurations, returning events etc. |
@tehhowch @christian-bromann any suggestions? |
@DrewciferB can confirm, that patching that line works. Should this be fixed? |
@franklinkim I recommend upgrading to v8 where this issue should not persist anymore. Feel free to raise a PR with a fix to the |
@christian-bromann I've upgraded to v8, but it still persists. |
Yes and it is quite annoying with typescript :/ |
facing the same issue in wdio v8 |
Hi there, I'm getting the following error on compile after updating WDIO to v7. Everything works fine under v6.
It seems that intercept service is defining a type based on an extension of Webdriver.Client, but the global namespace no longer exports Client as an interface in WDIO v7? I admit I'm quite out of my depth here, so apologies if I've missed something basic.
I have Intercept v4.2.1 specified in package.json:
"wdio-intercept-service": "^4.2.1",
Here are my tsconfig.json types
"types": ["node", "webdriverio/sync", "@wdio/mocha-framework", "wdio-intercept-service"]
I notice that the types changed in v7 from
@wdio/sync
towebdriverio/sync
, not sure if that has anything to do with this but the error seems to be happening around code that is concerned with detecting sync mode, so I thought it might be relevant (fromwdio-intercept-service/types/wdio-intercept-service.d.ts
):Even installing a brand new v7 webdriver project into a blank folder and then adding the intercept service still triggered this error, and it also occurs regardless of whether @wdio/sync is installed or not. Any help much appreciated 👍
The text was updated successfully, but these errors were encountered: