Skip to content

Conversation

nlespiaucq
Copy link
Contributor

Motivation/Description of the PR

Since the last update, there are warnings in the console during the set-up of helper Playwright.

selectors.register: "__value" selector engine has been already registered
    at async Playwright._init (/Users/xxx/end-to-end-tests/node_modules/codeceptjs/lib/helper/Playwright.js:485:9) {
  name: 'Error'
}

I tried to investigate it may come from the following change #5090
Actually, the _init method is called twice (causing warning) and I guess there is a concurrent run. I think it's because of this call:

// Call _init() to register selector engines - use setTimeout to avoid blocking constructor
setTimeout(() => {
this._init().catch(console.error)
}, 0)

Note: this is a new behaviour has been introduced in the version 3.7.5 - version 3.7.4 called only once the _init method
This PR doesn't fix the root cause, but prevent user to receive confused message when they run tests.

Applicable helpers:

  • Playwright
  • Puppeteer
  • WebDriver
  • REST
  • FileHelper
  • Appium
  • TestCafe

Applicable plugins:

  • allure
  • autoDelay
  • autoLogin
  • customLocator
  • pauseOnFail
  • coverage
  • retryFailedStep
  • screenshotOnFail
  • selenoid
  • stepByStepReport
  • stepTimeout
  • wdio
  • subtitles

Type of change

  • 🔥 Breaking changes
  • 🚀 New functionality
  • 🐛 Bug fix
  • 🧹 Chore
  • 📋 Documentation changes/updates
  • ♨️ Hot fix
  • 🔨 Markdown files fix - not related to source code
  • 💅 Polish code

Checklist:

  • Tests have been added
  • Documentation has been added (Run npm run docs)
  • Lint checking (Run npm run lint)
  • Local tests are passed (Run npm test)

@kobenguyent
Copy link
Collaborator

hi @nlespiaucq I guess this issue is addressed by #5206

@nlespiaucq
Copy link
Contributor Author

nlespiaucq commented Oct 3, 2025

hi @nlespiaucq I guess this issue is addressed by #5206

Ah yes, indeed - I have checked the existing issues, but haven't though to look for completed PR.
Thanks for the fix @kobenguyent, I will close mine

@nlespiaucq nlespiaucq closed this Oct 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants