-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed as not planned
Labels
Description
Have you read the Contributing Guidelines on issues?
- I have read the Contributing Guidelines on issues.
WebdriverIO Version
9.1.2
Node.js Version
v20.15.0
Mode
Standalone Mode
Which capabilities are you using?
{
// capabilities for local browser web tests
browserName: 'chrome', // or "firefox", "microsoftedge", "safari"
"goog:chromeOptions": {
args: [
'--no-sandbox',
'--remote-debugging-pipe',
'--headless',
'--disable-gpu',
'--disable-dev-shm-usage',
`--window-size=${width},${height}`,
'--disable-infobars',
],
},
}What happened?
I ran npm run wdio and it fails when my code gets to const puppeteerBrowser = await browser.getPuppeteer() with this error: [chrome 129.0.6668.89 linux #0-0] Error: Using DevTools capabilities is not supported for this session. This feature is only supported for local testing on Chrome, Firefox and Chromium Edge.
What is your expected behavior?
I expected the test suite to pass, which it does when I don't try to use Puppeteer.
How to reproduce the bug.
Check out this toy example: https://github.com/SeanHayes/wdiotest/tree/main
Relevant log output
$ npm run wdio
> wdio
> wdio run ./wdio.conf.js
Execution of 1 workers started at 2024-10-07T20:45:30.962Z
2024-10-07T20:45:30.970Z INFO @wdio/cli:launcher: Run onPrepare hook
2024-10-07T20:45:30.971Z INFO @wdio/utils: Setting up browser driver for: chrome@stable
2024-10-07T20:45:30.975Z INFO @wdio/utils: Setting up browser binaries for: chrome@stable
2024-10-07T20:45:31.065Z INFO webdriver: Using Chromedriver v129.0.6668.89 from cache directory /tmp
2024-10-07T20:45:31.067Z INFO @wdio/cli:launcher: Run onWorkerStart hook
2024-10-07T20:45:31.068Z INFO @wdio/local-runner: Start worker 0-0 with arg: run ./wdio.conf.js
[0-0] 2024-10-07T20:45:31.930Z INFO @wdio/local-runner: Run worker command: run
[0-0] RUNNING in chrome - file:///test/specs/test.e2e.js
[0-0] 2024-10-07T20:45:32.002Z INFO webdriver: Initiate new session using the WebDriver protocol
[0-0] 2024-10-07T20:45:32.062Z INFO webdriver: Using Chromedriver v129.0.6668.89 from cache directory /tmp
[0-0] 2024-10-07T20:45:32.073Z INFO chromedriver: Starting ChromeDriver 129.0.6668.89 (951c0b97221f8d4ba37cf97d324505c832251cf9-refs/branch-heads/6668@{#1503}) on port 40875
[0-0] 2024-10-07T20:45:32.073Z INFO chromedriver: Remote connections are allowed by an allowlist (0.0.0.0).
[0-0] 2024-10-07T20:45:32.073Z INFO chromedriver: Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
[0-0] 2024-10-07T20:45:32.074Z INFO chromedriver: ChromeDriver was started successfully on port 40875.
[0-0] 2024-10-07T20:45:32.074Z INFO @wdio/utils: Started Chromedriver v129.0.6668.89 with params --port=40875 --allowed-origins=* --allowed-ips=0.0.0.0 in 71ms on port 40875
[0-0] 2024-10-07T20:45:32.086Z INFO webdriver: [POST] http://localhost:40875/session
[0-0] 2024-10-07T20:45:32.086Z INFO webdriver: DATA {
[0-0] capabilities: {
[0-0] alwaysMatch: {
[0-0] browserName: 'chrome',
[0-0] 'goog:chromeOptions': [Object],
[0-0] webSocketUrl: true
[0-0] },
[0-0] firstMatch: [ {} ]
[0-0] }
[0-0] }
[0-0] 2024-10-07T20:45:33.406Z INFO webdriver: Register BiDi handler for session with id c5694fe9208ed88ad1c5fb750bb11761
[0-0] 2024-10-07T20:45:33.407Z INFO webdriver: Connect to webSocketUrl ws://127.0.0.1:40875/session/c5694fe9208ed88ad1c5fb750bb11761
[0-0] 2024-10-07T20:45:33.415Z INFO webdriver: Connected session to Bidi protocol
[0-0] 2024-10-07T20:45:33.415Z INFO webdriver: Connected session to Bidi protocol
[0-0] 2024-10-07T20:45:33.415Z INFO webdriver: Connected to WebDriver Bidi interface at ws://127.0.0.1:40875/session/c5694fe9208ed88ad1c5fb750bb11761
[0-0] 2024-10-07T20:45:33.415Z INFO webdriver: BIDI COMMAND session.subscribe {"events":["browsingContext.navigationStarted"]}
[0-0] 2024-10-07T20:45:33.417Z INFO webdriver: COMMAND getWindowHandle()
[0-0] 2024-10-07T20:45:33.417Z INFO webdriver: BIDI COMMAND session.subscribe {"events":["log.entryAdded","browsingContext.navigationStarted"]}
[0-0] 2024-10-07T20:45:33.417Z INFO webdriver: BIDI COMMAND script.addPreloadScript { functionDeclaration: <PreloadScript[1267 bytes]>, contexts: undefined }
[0-0] 2024-10-07T20:45:33.418Z INFO webdriver: BIDI COMMAND session.subscribe {"events":["browsingContext.navigationStarted","network.responseCompleted","network.beforeRequestSent","network.fetchError"]}
[0-0] 2024-10-07T20:45:33.418Z INFO webdriver: BIDI COMMAND session.subscribe {"events":["browsingContext.userPromptOpened"]}
[0-0] 2024-10-07T20:45:33.418Z INFO webdriver: [GET] http://localhost:40875/session/c5694fe9208ed88ad1c5fb750bb11761/window
[0-0] 2024-10-07T20:45:33.419Z INFO webdriver: COMMAND getWindowHandle()
[0-0] 2024-10-07T20:45:33.419Z INFO webdriver: [GET] http://localhost:40875/session/c5694fe9208ed88ad1c5fb750bb11761/window
[0-0] 2024-10-07T20:45:33.421Z INFO webdriver: RESULT CCD6516A466B77403E34C7A4C36B732E
[0-0] 2024-10-07T20:45:33.421Z INFO webdriver: BIDI COMMAND script.callFunction {"functionDeclaration":"<Function[374 bytes]>","awaitPromise":true,"arguments":[],"target":{"context":"CCD6516A466B77403E34C7A4C36B732E"}}
[0-0] 2024-10-07T20:45:33.424Z INFO webdriver: RESULT CCD6516A466B77403E34C7A4C36B732E
[0-0] 2024-10-07T20:45:33.424Z INFO webdriver: BIDI COMMAND script.addPreloadScript { functionDeclaration: <PreloadScript[343 bytes]>, contexts: ["CCD6516A466B77403E34C7A4C36B732E"] }
[0-0] 2024-10-07T20:45:33.431Z INFO webdriver: BIDI COMMAND session.subscribe {"events":["script.message"]}
[0-0] 2024-10-07T20:45:33.433Z INFO webdriverio:PolyfillManager: polyfill script added
[0-0] 2024-10-07T20:45:33.439Z INFO webdriver: BIDI COMMAND browsingContext.navigate {"context":"CCD6516A466B77403E34C7A4C36B732E","url":"https://the-internet.herokuapp.com/login","wait":"complete"}
[0-0] 2024-10-07T20:45:33.443Z INFO webdriver: COMMAND getWindowHandle()
[0-0] 2024-10-07T20:45:33.443Z INFO webdriver: [GET] http://localhost:40875/session/c5694fe9208ed88ad1c5fb750bb11761/window
[0-0] 2024-10-07T20:45:33.445Z INFO webdriver: RESULT CCD6516A466B77403E34C7A4C36B732E
[0-0] 2024-10-07T20:45:33.445Z INFO webdriverio:ContextManager: Update current context: CCD6516A466B77403E34C7A4C36B732E
[0-0] got url
[0-0] Error in "My Login application should login with valid credentials"
at async UserContext.<anonymous> (file:///usr/local/foo/home/username/dev/wdiotest/test/specs/test.e2e.js:7:34)
[0-0] 2024-10-07T20:45:34.620Z INFO webdriver: COMMAND deleteSession()
[0-0] 2024-10-07T20:45:34.620Z INFO webdriver: [DELETE] http://localhost:40875/session/c5694fe9208ed88ad1c5fb750bb11761
[0-0] 2024-10-07T20:45:34.673Z INFO webdriver: RESULT null
[0-0] 2024-10-07T20:45:34.673Z INFO webdriver: Kill driver process with PID 293922
[0-0] FAILED in chrome - file:///test/specs/test.e2e.js
2024-10-07T20:45:34.801Z INFO @wdio/cli:launcher: Run onWorkerEnd hook
2024-10-07T20:45:34.801Z INFO @wdio/cli:launcher: Run onComplete hook
"spec" Reporter:
------------------------------------------------------------------
[chrome 129.0.6668.89 linux #0-0] Running: chrome (v129.0.6668.89) on linux
[chrome 129.0.6668.89 linux #0-0] Session ID: c5694fe9208ed88ad1c5fb750bb11761
[chrome 129.0.6668.89 linux #0-0]
[chrome 129.0.6668.89 linux #0-0] » file:///test/specs/test.e2e.js
[chrome 129.0.6668.89 linux #0-0] My Login application
[chrome 129.0.6668.89 linux #0-0] ✖ should login with valid credentials
[chrome 129.0.6668.89 linux #0-0]
[chrome 129.0.6668.89 linux #0-0] 1 failing (1.2s)
[chrome 129.0.6668.89 linux #0-0]
[chrome 129.0.6668.89 linux #0-0] 1) My Login application should login with valid credentials
[chrome 129.0.6668.89 linux #0-0] Error: Using DevTools capabilities is not supported for this session. This feature is only supported for local testing on Chrome, Firefox and Chromium Edge.
[chrome 129.0.6668.89 linux #0-0] at async UserContext.<anonymous> (file:///usr/local/foo/home/username/dev/wdiotest/test/specs/test.e2e.js:7:34)
Spec Files: 0 passed, 1 failed, 1 total (100% completed) in 00:00:03
2024-10-07T20:45:34.802Z INFO @wdio/local-runner: Shutting down spawned worker
2024-10-07T20:45:35.054Z INFO @wdio/local-runner: Waiting for 0 to shut down gracefully
2024-10-07T20:45:35.054Z INFO @wdio/local-runner: shutting downCode 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
Reactions are currently unavailable