Skip to content

fix(util): recognize *.bsstag.com hosts as BrowserStack (v8, SDK-6948) - #183

Open
AakashHotchandani wants to merge 1 commit into
v8from
SDK-6948-v8-bsstag-host-recognition
Open

fix(util): recognize *.bsstag.com hosts as BrowserStack (v8, SDK-6948)#183
AakashHotchandani wants to merge 1 commit into
v8from
SDK-6948-v8-bsstag-host-recognition

Conversation

@AakashHotchandani

Copy link
Copy Markdown
Collaborator

What

Ports the *.bsstag.com host-recognition fix (#56 / #65, which target main/v9) to the v8 release line.

getCloudProvider and the isBrowserstackInfra isBrowserstack helper only matched browserstack.com, so a session pointed at an internal staging env (*.bsstag.com) is classified as non-BrowserStack. The service then skips its instrumentation + GRR host rewriting (updateURLSForGRR), and the WebDriver hub stays on production.

Change (packages/browserstack-service/src/util.ts)

  • getCloudProvider: both hostname checks now also match bsstag.
  • isBrowserstackInfraisBrowserstack(str): now str.includes('browserstack.com') || str.includes('bsstag.com').

(Note: v8's isBrowserstack uses .includes() where v9 uses === / endsWith; adapted to the v8 form.)

Why v8

Internal staging consumers (e.g. App LCA / devapplca) run on WebdriverIO v8 (@wdio/browserstack-service 8.49.x/8.50.0), so the main/v9 PRs don't reach them. This unblocks staging-env WDIO runs on the v8 line.

Ref: SDK-6948 · binary #1559 · wdio #56/#65 (main/v9).

🤖 Generated with Claude Code

getCloudProvider and isBrowserstackInfra only matched browserstack.com, so
a session against an internal staging env (*.bsstag.com) was classified as
non-BrowserStack — the service skipped its instrumentation + GRR host
rewriting and the WebDriver hub stayed on prod. Recognize bsstag/.bsstag.com
in both guards. Ports #56/#65 (main/v9) to the v8 release line.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@AakashHotchandani
AakashHotchandani requested a review from a team as a code owner September 7, 2026 16:11
@AakashHotchandani
AakashHotchandani requested review from 07souravkunda and vivianludrick and removed request for a team September 7, 2026 16:11
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.

1 participant