The sdk branch appears to use framework: playwright, and this is GitHub repository is linked to in the setup documentation for Playwright and BrowserStack.
In the sdk branch, when you set retries: 3 in the playwright configuration file for re-running test failures and then run npm run sample-test command, (with your own user/access key) it marks the tests in BrowserStack as passed, but throws these errors in the console and the SDK marks the tests as failed, leading to it retrying over and over.
Running 4 tests using 2 workers
1) [playwright-firefox@latest:Windows 11@browserstack] › tests\bstack_test_add_to_cart.js:3:1 › BStackDemo test add to cart
Error: : expected object, got undefined
Retry #1 ───────────────────────────────────────────────────────────────────────────────────────
Error: : expected object, got undefined
Retry #2 ───────────────────────────────────────────────────────────────────────────────────────
Error: : expected object, got undefined
Retry #3 ───────────────────────────────────────────────────────────────────────────────────────
Error: : expected object, got undefined
But in BrowserStack, it shows as passed sessions:

The
sdkbranch appears to useframework: playwright, and this is GitHub repository is linked to in the setup documentation for Playwright and BrowserStack.In the
sdkbranch, when you setretries: 3in the playwright configuration file for re-running test failures and then runnpm run sample-testcommand, (with your own user/access key) it marks the tests in BrowserStack as passed, but throws these errors in the console and the SDK marks the tests as failed, leading to it retrying over and over.But in BrowserStack, it shows as passed sessions:
