-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Description
Have you read the Contributing Guidelines on issues?
- I have read the Contributing Guidelines on issues.
WebdriverIO Version
latest
Node.js Version
v20.9.0
Mode
WDIO Testrunner
Which capabilities are you using?
capabilities: {
myAppiumDriver: {
capabilities: {
platformName,
'appium:platformVersion': process.env.OS_VERSION,
'appium:deviceName': process.env.DEVICE,
'appium:app': process.env.BROWSERSTACK_APP_ID,
'appium:optionalIntentArguments': '--ez autoBindDevice true',
'appium:processArguments': '{ "args": ["-autoBindDevice", "true"] }',
'appium:automationName': automationName,
'appium:build': `${ENV} ${platformName} ${bitriseBuildNumber}`,
'appium:projectName': `${appName} WDIO Automation`,
'appium:noReset': false,
'appium:autoGrantPermissions': true, // Android only
'bstack:options': {
appiumVersion: '2.6.0',
buildName: `${ENV} ${platformName} ${bitriseBuildNumber} ${environments.LANG}`,
userName: process.env.BROWSERSTACK_USERNAME,
accessKey: process.env.BROWSERSTACK_ACCESS_KEY,
enableBiometric: true,
idleTimeout: '4000',
},
},
},
},What happened?
We using parallel runs in BrowserStack real devices (using 'maxInstances' setting)
We use the BDD approach and have many Feature files with testing scenarios
After updating to WDIO v9 I've noticed that not all tests were completed during parallel runs
For example, we have 10 Feature files with scenarios and set 'maxInstances: 6' - and as a result, we got only results of the first 6 feature scenarios assigned on free 6 BS parallel devices, and all other attempts to run 4 Feature files which are left are failed with the following error in logs:
2024-08-19T08:54:29.897Z INFO @wdio/local-runner: Run worker command: run
2024-08-19T08:54:33.694Z DEBUG @wdio/runner: init multiremote session
2024-08-19T08:54:33.767Z ERROR @wdio/runner: Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/webdriverio/build/protocol-stub.js' imported from /builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/webdriverio/build/index.js
at new NodeError (node:internal/errors:406:5)
at finalizeResolution (node:internal/modules/esm/resolve:233:11)
at moduleResolve (node:internal/modules/esm/resolve:845:10)
at defaultResolve (node:internal/modules/esm/resolve:1043:11)
at nextResolve (node:internal/modules/esm/hooks:833:28)
at resolveBase (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:3126)
at async resolveDirectory (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:3492)
at async resolve (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:4355)
at async nextResolve (node:internal/modules/esm/hooks:833:22)
at async Hooks.resolve (node:internal/modules/esm/hooks:278:24)
With WDIO v8 this problem is not reproduced
What is your expected behavior?
All tests should be successfully executed during parallel runs using BrowserStack devices
How to reproduce the bug.
It's hard to create a reproducible example of this issue because BrowserStack requires setting up personal tokens to trigger runs on their side
I tried to add as much as possible info inside What's happened section
Relevant log output
2024-08-19T08:54:29.897Z INFO @wdio/local-runner: Run worker command: run
2024-08-19T08:54:33.694Z DEBUG @wdio/runner: init multiremote session
2024-08-19T08:54:33.767Z ERROR @wdio/runner: Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/webdriverio/build/protocol-stub.js' imported from /builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/webdriverio/build/index.js
at new NodeError (node:internal/errors:406:5)
at finalizeResolution (node:internal/modules/esm/resolve:233:11)
at moduleResolve (node:internal/modules/esm/resolve:845:10)
at defaultResolve (node:internal/modules/esm/resolve:1043:11)
at nextResolve (node:internal/modules/esm/hooks:833:28)
at resolveBase (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:3126)
at async resolveDirectory (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:3492)
at async resolve (file:///builds/bb2-bank/qa-testing/nomo-e2e-testing/node_modules/tsx/dist/esm/index.mjs?1724057651811:2:4355)
at async nextResolve (node:internal/modules/esm/hooks:833:22)
at async Hooks.resolve (node:internal/modules/esm/hooks:278:24)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