From 830f55f1dd03c1fb1900e1359e255e867247d828 Mon Sep 17 00:00:00 2001 From: Bumpsnag bot <> Date: Thu, 25 Sep 2025 18:45:00 +0000 Subject: [PATCH 01/15] Update bugsnag-cocoa to v6.34.0 [full ci] --- CHANGELOG.md | 4 ++++ packages/react-native/ios/vendor/bugsnag-cocoa | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ba354b53d9..a94af3396d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,10 @@ - (plugin-window-onerror) Guard against errors when trying to call previous handler [#2551](https://github.com/bugsnag/bugsnag-js/pull/2551) +### Dependencies + +Update bugsnag-cocoa to [v6.34.0](https//github.com/bugsnag/bugsnag-cocoa/releases/tag/v6.34.0) [#2571](https://github.com/bugsnag/bugsnag-js/pull/2571) + ## [8.5.0] - 2025-09-01 ### Added diff --git a/packages/react-native/ios/vendor/bugsnag-cocoa b/packages/react-native/ios/vendor/bugsnag-cocoa index 8dcc68b843..1f991e92a6 160000 --- a/packages/react-native/ios/vendor/bugsnag-cocoa +++ b/packages/react-native/ios/vendor/bugsnag-cocoa @@ -1 +1 @@ -Subproject commit 8dcc68b843fe38c67075d32e9532be76ee388ed9 +Subproject commit 1f991e92a6e3993c2763d071781d895ca4075a90 From 0af2aa1115816609301a9283b8bb711595605f85 Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Fri, 26 Sep 2025 11:50:27 +0100 Subject: [PATCH 02/15] ci: :twisted_rightwards_arrows: add github action to keep next in sync with main --- .github/workflows/branch-sync.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/branch-sync.yml diff --git a/.github/workflows/branch-sync.yml b/.github/workflows/branch-sync.yml new file mode 100644 index 0000000000..9971d40edb --- /dev/null +++ b/.github/workflows/branch-sync.yml @@ -0,0 +1,26 @@ +name: Sync main to next +on: + push: + branches: [main] + +jobs: + sync: + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Sync main to next + uses: bugsnag/github-action-branch-sync@v1 + with: + source-branch: main + target-branch: next + labels: automation + reviewers: ${{ secrets.AUTOMATION_REVIEWERS }} + team-reviewers: ${{ secrets.AUTOMATION_TEAM_REVIEWERS }} + github-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From 7179febf4e286186a70025aa091119c06d7f7356 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Sep 2025 03:40:20 +0000 Subject: [PATCH 03/15] build(deps): bump github/codeql-action from 3.30.3 to 3.30.5 Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.30.3 to 3.30.5. - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/github/codeql-action/compare/192325c86100d080feab897ff886c34abd4c83a3...3599b3baa15b485a2e49ef411a7a4bb2452e7f93) --- updated-dependencies: - dependency-name: github/codeql-action dependency-version: 3.30.5 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/codeql.yml | 6 +++--- .github/workflows/scorecard.yml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index dfcd880f68..8d0ce6b740 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -47,7 +47,7 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3 + uses: github/codeql-action/init@3599b3baa15b485a2e49ef411a7a4bb2452e7f93 # v3.30.5 with: languages: ${{ matrix.language }} # If you wish to specify custom queries, you can do so here or in a config file. @@ -61,7 +61,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java). # If this step fails, then you should remove it and run the build manually (see below) - name: Autobuild - uses: github/codeql-action/autobuild@192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3 + uses: github/codeql-action/autobuild@3599b3baa15b485a2e49ef411a7a4bb2452e7f93 # v3.30.5 # â„šī¸ Command-line programs to run using the OS shell. # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun @@ -74,6 +74,6 @@ jobs: # ./location_of_script_within_repo/buildscript.sh - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3 + uses: github/codeql-action/analyze@3599b3baa15b485a2e49ef411a7a4bb2452e7f93 # v3.30.5 with: category: "/language:${{matrix.language}}" diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index c432b30f5f..7d50bbf326 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -68,7 +68,7 @@ jobs: # Upload the results to GitHub's code scanning dashboard (optional). # Commenting out will disable upload of results to your repo's Code Scanning dashboard - name: "Upload to code-scanning" - uses: github/codeql-action/upload-sarif@192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3 + uses: github/codeql-action/upload-sarif@3599b3baa15b485a2e49ef411a7a4bb2452e7f93 # v3.30.5 with: sarif_file: results.sarif From 9c75772af2559f5bd4e217153f8a95b6e80dd7ec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Sep 2025 03:42:01 +0000 Subject: [PATCH 04/15] build(deps): bump actions/cache from 4.2.4 to 4.3.0 Bumps [actions/cache](https://github.com/actions/cache) from 4.2.4 to 4.3.0. - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](https://github.com/actions/cache/compare/0400d5f644dc74513175e3cd8d07132dd4860809...0057852bfaa89a56745cba8c7296529d2fc39830) --- updated-dependencies: - dependency-name: actions/cache dependency-version: 4.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/test-electron.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-electron.yml b/.github/workflows/test-electron.yml index 4c61f1f51e..7ebee1bc47 100644 --- a/.github/workflows/test-electron.yml +++ b/.github/workflows/test-electron.yml @@ -30,7 +30,7 @@ jobs: if: ${{ !env.ACT }} run: | echo "::set-output name=dir::$(npm config get cache)" - - uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4 + - uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0 id: npm-cache if: ${{ !env.ACT }} with: From 51bdf10d59f485690e255c1c27a7524c41a2f34b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Sep 2025 03:44:12 +0000 Subject: [PATCH 05/15] build(deps): bump ruby/setup-ruby from 1.262.0 to 1.263.0 Bumps [ruby/setup-ruby](https://github.com/ruby/setup-ruby) from 1.262.0 to 1.263.0. - [Release notes](https://github.com/ruby/setup-ruby/releases) - [Changelog](https://github.com/ruby/setup-ruby/blob/master/release.rb) - [Commits](https://github.com/ruby/setup-ruby/compare/cf7216d52fba1017929b4d7162fabe2b30af5b49...0481980f17b760ef6bca5e8c55809102a0af1e5a) --- updated-dependencies: - dependency-name: ruby/setup-ruby dependency-version: 1.263.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/aws-lambda.yml | 2 +- .github/workflows/update-dependencies.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/aws-lambda.yml b/.github/workflows/aws-lambda.yml index 56a9d990b0..1e24dcfc37 100644 --- a/.github/workflows/aws-lambda.yml +++ b/.github/workflows/aws-lambda.yml @@ -24,7 +24,7 @@ jobs: - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 - name: Install Ruby - uses: ruby/setup-ruby@cf7216d52fba1017929b4d7162fabe2b30af5b49 + uses: ruby/setup-ruby@0481980f17b760ef6bca5e8c55809102a0af1e5a with: ruby-version: '3.1' diff --git a/.github/workflows/update-dependencies.yml b/.github/workflows/update-dependencies.yml index d357a6e37a..c7b01021f5 100644 --- a/.github/workflows/update-dependencies.yml +++ b/.github/workflows/update-dependencies.yml @@ -40,7 +40,7 @@ jobs: - run: git submodule update --init --recursive - name: Install ruby - uses: ruby/setup-ruby@cf7216d52fba1017929b4d7162fabe2b30af5b49 # v1.262.0 + uses: ruby/setup-ruby@0481980f17b760ef6bca5e8c55809102a0af1e5a # v1.263.0 with: ruby-version: 2.7 From 829d454f52b509e620e783e0c73cad67f4c75943 Mon Sep 17 00:00:00 2001 From: Yousif <74918474+yousif-bugsnag@users.noreply.github.com> Date: Tue, 30 Sep 2025 14:51:01 +0100 Subject: [PATCH 06/15] ci: update expo pipeline for v54 (#2562) --- .buildkite/basic/expo-pipeline.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.buildkite/basic/expo-pipeline.yml b/.buildkite/basic/expo-pipeline.yml index 79c1e71b15..80ab7586b8 100644 --- a/.buildkite/basic/expo-pipeline.yml +++ b/.buildkite/basic/expo-pipeline.yml @@ -8,29 +8,29 @@ steps: depends_on: "publish-js" trigger: "bugsnag-expo" build: - branch: "v53/next" + branch: "v54/next" env: BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}" BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}" # a branch name that's safe to use as a docker cache identifier BUGSNAG_JS_CACHE_SAFE_BRANCH_NAME: "${BRANCH_NAME}" - - label: "@bugsnag/expo v52/next" + - label: "@bugsnag/expo v53/next" depends_on: "publish-js" trigger: "bugsnag-expo" build: - branch: "v52/next" + branch: "v53/next" env: BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}" BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}" # a branch name that's safe to use as a docker cache identifier BUGSNAG_JS_CACHE_SAFE_BRANCH_NAME: "${BRANCH_NAME}" - - label: "@bugsnag/expo v51/next" + - label: "@bugsnag/expo v52/next" depends_on: "publish-js" trigger: "bugsnag-expo" build: - branch: "v51/next" + branch: "v52/next" env: BUGSNAG_JS_BRANCH: "${BUILDKITE_BRANCH}" BUGSNAG_JS_COMMIT: "${BUILDKITE_COMMIT}" From 9db3d94fbf3808e92b8904671453e97513a63232 Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Wed, 1 Oct 2025 09:42:12 +0100 Subject: [PATCH 07/15] Merge pull request #2481 from bugsnag/update-e2e-ios-12 Use iOS 12 in browser e2e tests --- .buildkite/basic/browser-pipeline.yml | 2 +- .../features/fixtures/browser_errors.yml | 28 +------------------ test/browser/features/integrity.feature | 2 +- test/browser/features/web_worker.feature | 3 +- 4 files changed, 5 insertions(+), 30 deletions(-) diff --git a/.buildkite/basic/browser-pipeline.yml b/.buildkite/basic/browser-pipeline.yml index 79b596dfd9..1de4d04cb8 100644 --- a/.buildkite/basic/browser-pipeline.yml +++ b/.buildkite/basic/browser-pipeline.yml @@ -50,7 +50,7 @@ steps: # - label: ":browserstack: {{matrix}} non-https tests" matrix: - # - ios_11 - Skipped pending PLAT-14437 + - ios_12 - safari_16 depends_on: "browser-maze-runner-bs" timeout_in_minutes: 30 diff --git a/test/browser/features/fixtures/browser_errors.yml b/test/browser/features/fixtures/browser_errors.yml index 610b2d2227..e3d1e46b42 100644 --- a/test/browser/features/fixtures/browser_errors.yml +++ b/test/browser/features/fixtures/browser_errors.yml @@ -103,33 +103,7 @@ safari_16: lineNumber: 18 columnNumber: 25 -ios_10: - handled: - errorClass: 'ReferenceError' - errorMessage: "Can't find variable: foo" - unhandled_syntax: - errorClass: 'SyntaxError' - errorMessage: "Unexpected token '!'. Parse error." - lineNumber: 18 - columnNumber: 0 - file: '/unhandled/script/a.html' - unhandled_thrown: - errorClass: 'Error' - errorMessage: "bad things" - lineNumber: 18 - columnNumber: 22 - unhandled_undefined_function: - errorClass: 'ReferenceError' - errorMessage: "Can't find variable: nevergoingtoexist_notinamillionyears" - lineNumber: 18 - columnNumber: 43 - unhandled_malformed_uri: - errorClass: 'URIError' - errorMessage: URI error - lineNumber: 18 - columnNumber: 25 - -ios_11: +ios_12: handled: errorClass: 'ReferenceError' errorMessage: "Can't find variable: foo" diff --git a/test/browser/features/integrity.feature b/test/browser/features/integrity.feature index 1e5eba9994..009fa26811 100644 --- a/test/browser/features/integrity.feature +++ b/test/browser/features/integrity.feature @@ -1,4 +1,4 @@ -@skip_ie_11 @skip_ios_10 @skip_safari_10 @skip_safari_16 @skip_edge_17 @skip_chrome_43 @skip_http +@skip_ie_11 @skip_safari_10 @skip_safari_16 @skip_edge_17 @skip_chrome_43 @skip_http Feature: Bugsnag-Integrity header Scenario: Integrity headers are set when setPayloadChecksums is true diff --git a/test/browser/features/web_worker.feature b/test/browser/features/web_worker.feature index 36bb588f62..8d59e23aec 100644 --- a/test/browser/features/web_worker.feature +++ b/test/browser/features/web_worker.feature @@ -47,7 +47,8 @@ Feature: worker notifier And I wait to receive a session Then the session is a valid browser payload for the session tracking API - @skip_safari_16 + # Not supported on Safari https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Integrity-Policy#browser_compatibility + @skip_safari_16 @skip_ios_12 Scenario: Integrity headers are set when setPayloadChecksums is true When I navigate to the test URL "/web_worker/integrity" And I wait to receive an error From d9a21d798d4a420cbf4da93ea6f6841d5a59241c Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Tue, 7 Oct 2025 13:59:42 +0100 Subject: [PATCH 08/15] Merge pull request #2577 from bugsnag/PLAT-14963/electron-code-bundle-id Add `codeBundleId` config option to main process --- CHANGELOG.md | 6 + package-lock.json | 2 + packages/electron/src/config/main.js | 5 + packages/electron/types/notifier.d.ts | 1 + packages/plugin-electron-app/app.js | 3 +- packages/plugin-electron-app/test/app.test.ts | 19 ++++ .../plugin-electron-ipc/bugsnag-ipc-main.js | 3 +- .../test/bugsnag-ipc-main.test.ts | 32 +++++- .../test/bugsnag-ipc-renderer.test.ts | 32 ++++++ .../test/renderer-event-data.test.ts | 44 +++++++- test/electron/features/error-handling.feature | 12 ++ .../electron/features/renderer-config.feature | 14 ++- .../features/support/steps/request-steps.js | 12 ++ .../app/src/configs/complex-config.js | 1 + .../app/src/configs/mixed-codebundleid.js | 14 +++ .../events/app-launch/complex-config.json | 1 + .../main/breadcrumbs/complex-config.json | 1 + .../main/handled-error/complex-config.json | 1 + .../handled-error/mixed-codebundleid.json | 101 +++++++++++++++++ .../uncaught-exception/complex-config.json | 1 + .../unhandled-rejection/complex-config.json | 1 + .../events/on-error/complex-config.json | 1 + .../renderer/config/mixed-codebundleid.json | 105 ++++++++++++++++++ .../page-title-clear-complex-config.json | 1 + .../page-title-update-complex-config.json | 1 + .../handled-error/complex-config.json | 1 + .../uncaught-exception/complex-config.json | 1 + .../unhandled-rejection/complex-config.json | 1 + .../events/sessions/complex-config.json | 1 + 29 files changed, 411 insertions(+), 7 deletions(-) create mode 100644 test/electron/fixtures/app/src/configs/mixed-codebundleid.js create mode 100644 test/electron/fixtures/events/main/handled-error/mixed-codebundleid.json create mode 100644 test/electron/fixtures/events/renderer/config/mixed-codebundleid.json diff --git a/CHANGELOG.md b/CHANGELOG.md index d2935cbcad..ee3a6adfbe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## [Unreleased] + +### Added + +- Add `codeBundleId` config option to main process [#2577](https://github.com/bugsnag/bugsnag-js/pull/2577) + ## [8.6.0] - 2025-09-25 ### Added diff --git a/package-lock.json b/package-lock.json index 234ffb7ab1..9488cfd1f2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -53001,6 +53001,7 @@ "packages/plugin-electron-app": { "name": "@bugsnag/plugin-electron-app", "version": "8.6.0", + "hasInstallScript": true, "license": "MIT", "dependencies": { "bindings": "^1.5.0" @@ -53042,6 +53043,7 @@ "packages/plugin-electron-client-state-persistence": { "name": "@bugsnag/plugin-electron-client-state-persistence", "version": "8.6.0", + "hasInstallScript": true, "license": "MIT", "dependencies": { "bindings": "^1.5.0" diff --git a/packages/electron/src/config/main.js b/packages/electron/src/config/main.js index 932e083de8..737eee5161 100644 --- a/packages/electron/src/config/main.js +++ b/packages/electron/src/config/main.js @@ -35,6 +35,11 @@ module.exports.schema = { validate: value => value === null || stringWithLength(value), message: 'should be string' }, + codeBundleId: { + defaultValue: () => undefined, + message: 'should be a string', + validate: val => (val === undefined || stringWithLength(val)) + }, releaseStage: { ...schema.releaseStage, defaultValue: () => app.isPackaged ? 'production' : 'development' diff --git a/packages/electron/types/notifier.d.ts b/packages/electron/types/notifier.d.ts index bd680fa6d9..aa10630ec0 100644 --- a/packages/electron/types/notifier.d.ts +++ b/packages/electron/types/notifier.d.ts @@ -26,6 +26,7 @@ interface MainConfig extends Config { projectRoot?: string launchDurationMillis?: number sendCode?: boolean + codeBundleId?: string } // a renderer is only allowed a subset of properties from Config diff --git a/packages/plugin-electron-app/app.js b/packages/plugin-electron-app/app.js index d01b68dbf5..4d2ee9e960 100644 --- a/packages/plugin-electron-app/app.js +++ b/packages/plugin-electron-app/app.js @@ -106,7 +106,8 @@ module.exports = (NativeClient, process, electronApp, BrowserWindow, filestore, isLaunching: true, releaseStage: client._config.releaseStage, type: client._config.appType || osToAppType.get(process.platform), - version: client._config.appVersion + version: client._config.appVersion, + codeBundleId: client._config.codeBundleId }) client.addMetadata('app', { diff --git a/packages/plugin-electron-app/test/app.test.ts b/packages/plugin-electron-app/test/app.test.ts index 3ca4e56633..d5b995b5ef 100644 --- a/packages/plugin-electron-app/test/app.test.ts +++ b/packages/plugin-electron-app/test/app.test.ts @@ -13,6 +13,7 @@ const makeExpectedSessionApp = (customisations = {}) => ({ releaseStage: 'production', type: undefined, version: '1.2.3', + codeBundleId: undefined, ...customisations }) @@ -181,6 +182,19 @@ describe('plugin: electron app info', () => { expect(session.app).toEqual(makeExpectedSessionApp()) }) + it('reports app.codeBundleId when configured', async () => { + const config = { codeBundleId: 'test-bundle-123' } + + const { sendEvent, sendSession } = makeClient({ config }) + + const event = await sendEvent() + expect(event.app).toEqual(makeExpectedEventApp({ codeBundleId: 'test-bundle-123' })) + expect(event.getMetadata('app')).toEqual(makeExpectedMetadataApp()) + + const session = await sendSession() + expect(session.app).toEqual(makeExpectedSessionApp({ codeBundleId: 'test-bundle-123' })) + }) + it('tracks focus and blur events for inForeground', async () => { const BrowserWindow = makeBrowserWindow() const electronApp = makeElectronApp({ BrowserWindow }) @@ -801,6 +815,11 @@ const schema = { }), allowPartialObject: true, validate: value => true + }, + codeBundleId: { + defaultValue: () => undefined, + message: 'should be a string', + validate: val => (val === undefined || typeof val === 'string') } } diff --git a/packages/plugin-electron-ipc/bugsnag-ipc-main.js b/packages/plugin-electron-ipc/bugsnag-ipc-main.js index 8d8a01a9e9..64656d2f2e 100644 --- a/packages/plugin-electron-ipc/bugsnag-ipc-main.js +++ b/packages/plugin-electron-ipc/bugsnag-ipc-main.js @@ -100,7 +100,8 @@ module.exports = class BugsnagIpcMain { ...event.app, releaseStage: this.client._config.releaseStage, version: this.client._config.appVersion, - type: this.client._config.appType + type: this.client._config.appType, + codeBundleId: this.client._config.codeBundleId } event.context = event.context || this.client._context event.groupingDiscriminator = event.groupingDiscriminator || this.client._groupingDiscriminator diff --git a/packages/plugin-electron-ipc/test/bugsnag-ipc-main.test.ts b/packages/plugin-electron-ipc/test/bugsnag-ipc-main.test.ts index 4abba5aa06..c75075256e 100644 --- a/packages/plugin-electron-ipc/test/bugsnag-ipc-main.test.ts +++ b/packages/plugin-electron-ipc/test/bugsnag-ipc-main.test.ts @@ -311,7 +311,8 @@ describe('BugsnagIpcMain', () => { releaseStage: 'production', name: 'testApp', type: 'test', - version: undefined + version: undefined, + codeBundleId: undefined }, breadcrumbs: client._breadcrumbs, context: 'ctx', @@ -335,6 +336,35 @@ describe('BugsnagIpcMain', () => { }) }) + it('should include codeBundleId in app object when configured', async () => { + const schema = { + codeBundleId: { + defaultValue: () => undefined, + message: 'should be a string', + validate: (val: unknown) => (val === undefined || typeof val === 'string') + }, + releaseStage: { + defaultValue: () => 'production', + message: 'should be a string', + validate: (val: unknown) => typeof val === 'string' + } + } + const client = new Client({ + apiKey: '123', + codeBundleId: 'test-bundle-456' + }, schema, [mockClientStateManagerPlugin], Notifier) + + const bugsnagIpcMain = new BugsnagIpcMain(client) + const payloadInfo = await bugsnagIpcMain.getPayloadInfo() + + expect(payloadInfo.app).toEqual({ + releaseStage: 'production', + version: undefined, + type: undefined, + codeBundleId: 'test-bundle-456' + }) + }) + it('should return shouldSend=false when a callback returns false', async () => { const cb = jest.fn(() => false) // @ts-expect-error _internal is not a property of jest mocks but if we diff --git a/packages/plugin-electron-ipc/test/bugsnag-ipc-renderer.test.ts b/packages/plugin-electron-ipc/test/bugsnag-ipc-renderer.test.ts index 6cbb8043f2..3cacb8c581 100644 --- a/packages/plugin-electron-ipc/test/bugsnag-ipc-renderer.test.ts +++ b/packages/plugin-electron-ipc/test/bugsnag-ipc-renderer.test.ts @@ -156,4 +156,36 @@ describe('BugsnagIpcRenderer', () => { await BugsnagIpcRenderer.dispatch(event) expect(electron.ipcRenderer.invoke).toHaveBeenCalledWith(CHANNEL_RENDERER_TO_MAIN, 'dispatch', JSON.stringify(event)) }) + + it('should receive main process codeBundleId via getPayloadInfo but not use it when renderer has no codeBundleId', async () => { + // Mock the electron.ipcRenderer.invoke to return payload info with main's codeBundleId + const mockPayloadInfo = { + app: { + releaseStage: 'production', + version: '1.0.0', + type: 'electron', + codeBundleId: 'main-bundle-abc123' + }, + breadcrumbs: [], + context: null, + device: {}, + metadata: {}, + features: [], + user: {}, + groupingDiscriminator: null + }; + + (electron.ipcRenderer.invoke as jest.Mock).mockResolvedValueOnce(mockPayloadInfo) + + // Verify that getPayloadInfo returns the main's codeBundleId + const result = await BugsnagIpcRenderer.getPayloadInfo() + + expect(electron.ipcRenderer.invoke).toHaveBeenCalledWith(CHANNEL_RENDERER_TO_MAIN, 'getPayloadInfo') + expect(result.app.codeBundleId).toBe('main-bundle-abc123') + + // Note: This test verifies the IPC transport mechanism works correctly. + // The actual isolation behavior (preventing main's codeBundleId from being used + // when renderer has no codeBundleId) is enforced by the renderer-event-data plugin + // which explicitly sets codeBundleId from the renderer's own config. + }) }) diff --git a/packages/plugin-electron-renderer-event-data/test/renderer-event-data.test.ts b/packages/plugin-electron-renderer-event-data/test/renderer-event-data.test.ts index 17ee8fbec7..fb52bd3aed 100644 --- a/packages/plugin-electron-renderer-event-data/test/renderer-event-data.test.ts +++ b/packages/plugin-electron-renderer-event-data/test/renderer-event-data.test.ts @@ -22,8 +22,9 @@ describe('plugin: electron renderer event data', () => { const features = [{ name: 'flag1', variant: 'variant1' }] const metadata = { meta: { data: true } } const groupingDiscriminator = 'test-discriminator' + const codeBundleId = 'main-bundle-123' - const { sendEvent } = makeClient({ context, breadcrumbs, app, device, user, features, metadata, groupingDiscriminator }) + const { sendEvent } = makeClient({ context, breadcrumbs, app, device, user, features, metadata, groupingDiscriminator, codeBundleId }) const event = await sendEvent() @@ -66,7 +67,44 @@ describe('plugin: electron renderer event data', () => { expect(event.getUser()).toStrictEqual({ id: 456, email: 'abc@example.com', name: 'abc' }) }) + + it('does not use main process codeBundleId when renderer has no codeBundleId set', async () => { + // Simulate main process having a codeBundleId but renderer config having undefined + const mainProcessPayload = { + app: { + releaseStage: 'production', + version: '1.0.0', + type: 'electron', + codeBundleId: 'main-bundle-abc123' // This should NOT be used by renderer + }, + breadcrumbs: [], + context: null, + device: {}, + metadata: {}, + features: [], + user: {}, + groupingDiscriminator: null + } + + // Create client with no codeBundleId in renderer config (undefined) + const { sendEvent } = makeClientForPlugin({ + plugins: [plugin(makeIpcRenderer(mainProcessPayload))], + config: { + // Explicitly omit codeBundleId to simulate renderer with no codeBundleId config + } + }) + + const event = await sendEvent() + + // The renderer should use its own config value (undefined), not the main process value + expect(event.app.codeBundleId).toBeUndefined() + + // Verify other app properties from main process are still applied + expect(event.app.releaseStage).toBe('production') + expect(event.app.version).toBe('1.0.0') + expect(event.app.type).toBe('electron') + }) }) -const makeClient = payloadInfo => makeClientForPlugin({ plugins: [plugin(makeIpcRenderer(payloadInfo))] }) -const makeIpcRenderer = payloadInfo => ({ getPayloadInfo: async () => payloadInfo }) +const makeClient = (payloadInfo: any) => makeClientForPlugin({ plugins: [plugin(makeIpcRenderer(payloadInfo))] }) +const makeIpcRenderer = (payloadInfo: any) => ({ getPayloadInfo: async () => payloadInfo }) diff --git a/test/electron/features/error-handling.feature b/test/electron/features/error-handling.feature index eb7a7065f9..9a1008913a 100644 --- a/test/electron/features/error-handling.feature +++ b/test/electron/features/error-handling.feature @@ -105,3 +105,15 @@ Feature: Detecting and reporting errors | config | | default | | complex-config | + + Scenario: Main process uses main codeBundleId when different from renderer + Given I launch an app with configuration: + | bugsnag | mixed-codebundleid | + When I click "main-notify" + Then the total requests received by the server matches: + | events | 1 | + Then the headers of every event request contains: + | Bugsnag-API-Key | 6425093c6530f554a9897d2d7d38e248 | + | Content-Type | application/json | + | Bugsnag-Integrity | {BODY_SHA1} | + Then the contents of an event request matches "main/handled-error/mixed-codebundleid.json" diff --git a/test/electron/features/renderer-config.feature b/test/electron/features/renderer-config.feature index d8ede118ca..3c6553bc93 100644 --- a/test/electron/features/renderer-config.feature +++ b/test/electron/features/renderer-config.feature @@ -37,4 +37,16 @@ Feature: Setting config options in renderers | property | config | | clear-user | { "user": { "id": "3", "name": "Bugs Nag", "email": "bugs.nag@bugsnag.com" } } | | clear-context | { "context": "renderer context" } | - | clear-metadata | { "metadata": { "renderer": { "key": "value" } } } | \ No newline at end of file + | clear-metadata | { "metadata": { "renderer": { "key": "value" } } } | + + Scenario: Different codeBundleId values in main and renderer processes + Given I launch an app with configuration: + | bugsnag | mixed-codebundleid | + And I click "renderer-notify" + Then the total requests received by the server matches: + | events | 1 | + Then the headers of every event request contains: + | Bugsnag-API-Key | 6425093c6530f554a9897d2d7d38e248 | + | Content-Type | application/json | + | Bugsnag-Integrity | {BODY_SHA1} | + Then the contents of an event request matches "renderer/config/mixed-codebundleid.json" \ No newline at end of file diff --git a/test/electron/features/support/steps/request-steps.js b/test/electron/features/support/steps/request-steps.js index 49db7cd3cb..ffaeab856e 100644 --- a/test/electron/features/support/steps/request-steps.js +++ b/test/electron/features/support/steps/request-steps.js @@ -41,6 +41,18 @@ Given('I launch an app with configuration:', launchConfig, (data) => { setup[key] = config }) + // If no explicit renderer_config was provided, check if the bugsnag config file has a renderer export + if (setup.renderer_config === '{}' && setup.bugsnag !== 'default') { + try { + const configModule = require(`../../../fixtures/app/src/configs/${setup.bugsnag}.js`) + if (typeof configModule.renderer === 'function') { + setup.renderer_config = JSON.stringify(configModule.renderer()) + } + } catch (e) { + // If the config file doesn't exist or doesn't have a renderer export, use the default + } + } + return global.automator.start({ BUGSNAG_CONFIG: setup.bugsnag, BUGSNAG_PRELOAD: setup.preload, diff --git a/test/electron/fixtures/app/src/configs/complex-config.js b/test/electron/fixtures/app/src/configs/complex-config.js index 540a85f7af..c49cc3b6b9 100644 --- a/test/electron/fixtures/app/src/configs/complex-config.js +++ b/test/electron/fixtures/app/src/configs/complex-config.js @@ -2,6 +2,7 @@ module.exports = () => { return { appType: 'complicated', appVersion: '2.0.83-beta3', + codeBundleId: '2.0.83-beta3-r456', context: 'shopping cart', user: { id: '3', diff --git a/test/electron/fixtures/app/src/configs/mixed-codebundleid.js b/test/electron/fixtures/app/src/configs/mixed-codebundleid.js new file mode 100644 index 0000000000..399b68f084 --- /dev/null +++ b/test/electron/fixtures/app/src/configs/mixed-codebundleid.js @@ -0,0 +1,14 @@ +module.exports = () => { + return { + appType: 'mixed-bundle', + appVersion: '1.0.0', + codeBundleId: 'main-bundle-abc123', + releaseStage: 'test' + } +} + +module.exports.renderer = () => { + return { + codeBundleId: 'renderer-bundle-xyz789' + } +} diff --git a/test/electron/fixtures/events/app-launch/complex-config.json b/test/electron/fixtures/events/app-launch/complex-config.json index 8911ca9a67..d893ba84f2 100644 --- a/test/electron/fixtures/events/app-launch/complex-config.json +++ b/test/electron/fixtures/events/app-launch/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/main/breadcrumbs/complex-config.json b/test/electron/fixtures/events/main/breadcrumbs/complex-config.json index 48b6d860b5..55c605e331 100644 --- a/test/electron/fixtures/events/main/breadcrumbs/complex-config.json +++ b/test/electron/fixtures/events/main/breadcrumbs/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/main/handled-error/complex-config.json b/test/electron/fixtures/events/main/handled-error/complex-config.json index d3606af6cb..3b8acdcb17 100644 --- a/test/electron/fixtures/events/main/handled-error/complex-config.json +++ b/test/electron/fixtures/events/main/handled-error/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/main/handled-error/mixed-codebundleid.json b/test/electron/fixtures/events/main/handled-error/mixed-codebundleid.json new file mode 100644 index 0000000000..48d219fc55 --- /dev/null +++ b/test/electron/fixtures/events/main/handled-error/mixed-codebundleid.json @@ -0,0 +1,101 @@ +{ + "apiKey": "6425093c6530f554a9897d2d7d38e248", + "notifier": { + "name": "Bugsnag Electron", + "url": "https://github.com/bugsnag/bugsnag-electron", + "version": "{REGEX:^200\\.1\\.0-canary\\.[0-9a-f]{24}$}" + }, + "events": [ + { + "payloadVersion": "4", + "app": { + "codeBundleId": "main-bundle-abc123", + "duration": "{TYPE:number}", + "releaseStage": "test", + "inForeground": "{TYPE:boolean}", + "isLaunching": "{TYPE:boolean}", + "type": "mixed-bundle", + "version": "1.0.0" + }, + "device": { + "runtimeVersions": { + "node": "{TYPE:string}", + "chrome": "{TYPE:string}", + "electron": "{TYPE:string}" + }, + "id": "{REGEX:[0-9a-f]{64}}", + "freeMemory": "{TYPE:number}", + "time": "{TIMESTAMP}", + "totalMemory": "{TYPE:number}", + "osVersion": "{REGEX:\\d+\\.\\d+}" + }, + "metaData": { + "app": { + "name": "Runner", + "CFBundleVersion": "{PLATFORM_MACOS:1.0.2}" + }, + "device": { + "online": "{TYPE:boolean}", + "idleTime": "{TYPE:number}", + "screenResolution": { + "width": "{TYPE:number}", + "height": "{TYPE:number}" + } + }, + "process": { + "type": "browser", + "heapStatistics": {} + } + }, + "severity": "warning", + "unhandled": false, + "severityReason": { + "type": "handledException" + }, + "breadcrumbs": [ + { + "type": "state", + "name": "Bugsnag loaded", + "timestamp": "{TIMESTAMP}", + "metaData": {} + }, + { + "type": "state", + "name": "App became ready", + "timestamp": "{TIMESTAMP}" + }, + { + "type": "state", + "name": "Browser window 1 created", + "timestamp": "{TIMESTAMP}", + "metaData": { + "id": 1 + } + }, + { + "type": "state", + "name": "Browser window 1 was shown", + "timestamp": "{TIMESTAMP}", + "metaData": { + "id": 1, + "title": "Runner" + } + } + ], + "exceptions": [ + { + "errorMessage": "something bad", + "errorClass": "ReferenceError", + "stacktrace": [{ + "file": ".webpack/main/index.js", + "lineNumber": 2, + "code": { + "1": "{TYPE:string}" + } + }], + "type": "electronnodejs" + } + ] + } + ] +} \ No newline at end of file diff --git a/test/electron/fixtures/events/main/uncaught-exception/complex-config.json b/test/electron/fixtures/events/main/uncaught-exception/complex-config.json index 20f1f34d64..5b4fbd9134 100644 --- a/test/electron/fixtures/events/main/uncaught-exception/complex-config.json +++ b/test/electron/fixtures/events/main/uncaught-exception/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/main/unhandled-rejection/complex-config.json b/test/electron/fixtures/events/main/unhandled-rejection/complex-config.json index b1dc77bc44..2cd2f0d531 100644 --- a/test/electron/fixtures/events/main/unhandled-rejection/complex-config.json +++ b/test/electron/fixtures/events/main/unhandled-rejection/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/on-error/complex-config.json b/test/electron/fixtures/events/on-error/complex-config.json index 1af891d6b2..cf06bbf866 100644 --- a/test/electron/fixtures/events/on-error/complex-config.json +++ b/test/electron/fixtures/events/on-error/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/renderer/config/mixed-codebundleid.json b/test/electron/fixtures/events/renderer/config/mixed-codebundleid.json new file mode 100644 index 0000000000..e6226bf41d --- /dev/null +++ b/test/electron/fixtures/events/renderer/config/mixed-codebundleid.json @@ -0,0 +1,105 @@ +{ + "apiKey": "6425093c6530f554a9897d2d7d38e248", + "notifier": { + "name": "Bugsnag Electron", + "url": "https://github.com/bugsnag/bugsnag-electron", + "version": "{REGEX:^200\\.1\\.0-canary\\.[0-9a-f]{24}$}" + }, + "events": [ + { + "payloadVersion": "4", + "app": { + "codeBundleId": "renderer-bundle-xyz789", + "duration": "{TYPE:number}", + "releaseStage": "test", + "inForeground": "{TYPE:boolean}", + "isLaunching": "{TYPE:boolean}", + "type": "mixed-bundle", + "version": "1.0.0" + }, + "device": { + "runtimeVersions": { + "node": "{TYPE:string}", + "chrome": "{TYPE:string}", + "electron": "{TYPE:string}" + }, + "id": "{REGEX:[0-9a-f]{64}}", + "freeMemory": "{TYPE:number}", + "time": "{TIMESTAMP}", + "totalMemory": "{TYPE:number}", + "osVersion": "{REGEX:\\d+\\.\\d+}" + }, + "metaData": { + "app": { + "name": "Runner", + "CFBundleVersion": "{PLATFORM_MACOS:1.0.2}" + }, + "device": { + "online": "{TYPE:boolean}", + "idleTime": "{TYPE:number}", + "screenResolution": { + "width": "{TYPE:number}", + "height": "{TYPE:number}" + } + }, + "process": { + "type": "renderer", + "sandboxed": true, + "isMainFrame": true, + "heapStatistics": {} + } + }, + "severity": "warning", + "unhandled": false, + "severityReason": { + "type": "handledException" + }, + "breadcrumbs": [ + { + "type": "state", + "name": "Bugsnag loaded", + "timestamp": "{TIMESTAMP}", + "metaData": {} + }, + { + "type": "state", + "name": "App became ready", + "timestamp": "{TIMESTAMP}" + }, + { + "type": "state", + "name": "Browser window 1 created", + "timestamp": "{TIMESTAMP}", + "metaData": { + "id": 1 + } + }, + { + "type": "state", + "name": "Browser window 1 was shown", + "timestamp": "{TIMESTAMP}", + "metaData": { + "id": 1, + "title": "Runner" + } + } + ], + "exceptions": [ + { + "errorMessage": "{REGEX:ALERT!$}", + "errorClass": "Error", + "stacktrace": [ + { + "lineNumber": 1, + "file": ".webpack/renderer/main_window/index.js", + "code": { + "1": "{TYPE:string}" + } + } + ], + "type": "electronrendererjs" + } + ] + } + ] +} \ No newline at end of file diff --git a/test/electron/fixtures/events/renderer/context/page-title-clear-complex-config.json b/test/electron/fixtures/events/renderer/context/page-title-clear-complex-config.json index 7b9ba19a1d..2a0919a77e 100644 --- a/test/electron/fixtures/events/renderer/context/page-title-clear-complex-config.json +++ b/test/electron/fixtures/events/renderer/context/page-title-clear-complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/renderer/context/page-title-update-complex-config.json b/test/electron/fixtures/events/renderer/context/page-title-update-complex-config.json index 7b9ba19a1d..2a0919a77e 100644 --- a/test/electron/fixtures/events/renderer/context/page-title-update-complex-config.json +++ b/test/electron/fixtures/events/renderer/context/page-title-update-complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/renderer/handled-error/complex-config.json b/test/electron/fixtures/events/renderer/handled-error/complex-config.json index bb1cc772ef..645e2f3260 100644 --- a/test/electron/fixtures/events/renderer/handled-error/complex-config.json +++ b/test/electron/fixtures/events/renderer/handled-error/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/renderer/uncaught-exception/complex-config.json b/test/electron/fixtures/events/renderer/uncaught-exception/complex-config.json index b8f43f2427..52e6ff0544 100644 --- a/test/electron/fixtures/events/renderer/uncaught-exception/complex-config.json +++ b/test/electron/fixtures/events/renderer/uncaught-exception/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/renderer/unhandled-rejection/complex-config.json b/test/electron/fixtures/events/renderer/unhandled-rejection/complex-config.json index 3fc34940a4..48405c43f2 100644 --- a/test/electron/fixtures/events/renderer/unhandled-rejection/complex-config.json +++ b/test/electron/fixtures/events/renderer/unhandled-rejection/complex-config.json @@ -9,6 +9,7 @@ { "payloadVersion": "4", "app": { + "codeBundleId": "2.0.83-beta3-r456", "duration": "{TYPE:number}", "releaseStage": "beta", "inForeground": "{TYPE:boolean}", diff --git a/test/electron/fixtures/events/sessions/complex-config.json b/test/electron/fixtures/events/sessions/complex-config.json index 0a2328a0c7..6dc4ef5759 100644 --- a/test/electron/fixtures/events/sessions/complex-config.json +++ b/test/electron/fixtures/events/sessions/complex-config.json @@ -17,6 +17,7 @@ } }, "app": { + "codeBundleId": "2.0.83-beta3-r456", "releaseStage": "beta", "version": "2.0.83-beta3", "type": "complicated" From a5fc9f00051842f63f5eef5edf401eaff6efe66d Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Thu, 9 Oct 2025 17:11:56 +0100 Subject: [PATCH 09/15] test: :white_check_mark: skip failing react native navigation tests on android (#2585) --- .buildkite/basic/react-native-android-full-pipeline.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.buildkite/basic/react-native-android-full-pipeline.yml b/.buildkite/basic/react-native-android-full-pipeline.yml index 2148c45aeb..a46747f7e7 100644 --- a/.buildkite/basic/react-native-android-full-pipeline.yml +++ b/.buildkite/basic/react-native-android-full-pipeline.yml @@ -74,6 +74,7 @@ steps: - "0.79" - label: ':android: Build react-native-navigation {{matrix}} test fixture APK (Old Arch)' + skip: true # Skipped pending PLAT-15027 key: "build-react-native-navigation-android-fixture-old-arch" timeout_in_minutes: 30 agents: @@ -98,6 +99,7 @@ steps: limit: 1 - label: ':android: Build react-native-navigation {{matrix}} test fixture APK (New Arch)' + skip: true # Skipped pending PLAT-15027 key: "build-react-native-navigation-android-fixture-new-arch" timeout_in_minutes: 30 agents: @@ -216,6 +218,7 @@ steps: - "0.79" - label: ":bitbar: :android: react-native-navigation {{matrix}} Android 12 (Old Arch) end-to-end tests" + skip: true # Skipped pending PLAT-15027 depends_on: "build-react-native-navigation-android-fixture-old-arch" timeout_in_minutes: 10 plugins: @@ -257,6 +260,7 @@ steps: - "0.72" - label: ":bitbar: :android: react-native-navigation {{matrix}} Android 12 (New Arch) end-to-end tests" + skip: true # Skipped pending PLAT-15027 depends_on: "build-react-native-navigation-android-fixture-new-arch" timeout_in_minutes: 10 plugins: From d13ed539962c03271a34774e644a92693979c49d Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Fri, 10 Oct 2025 14:49:21 +0100 Subject: [PATCH 10/15] Revert browserstack non-https tests to ios_11 (#2586) * revert browserstack non-https tests to ios_11 * add android 9 test device * reinstate ios_11 browser error code assertions --- .buildkite/basic/browser-pipeline.yml | 7 ++--- .../features/fixtures/browser_errors.yml | 28 ++++++++++++++++++- 2 files changed, 30 insertions(+), 5 deletions(-) diff --git a/.buildkite/basic/browser-pipeline.yml b/.buildkite/basic/browser-pipeline.yml index 1de4d04cb8..b9eacee12b 100644 --- a/.buildkite/basic/browser-pipeline.yml +++ b/.buildkite/basic/browser-pipeline.yml @@ -50,7 +50,7 @@ steps: # - label: ":browserstack: {{matrix}} non-https tests" matrix: - - ios_12 + - ios_11 - safari_16 depends_on: "browser-maze-runner-bs" timeout_in_minutes: 30 @@ -82,7 +82,7 @@ steps: - edge_17 - safari_10 - ios_15 - - android_8 + - android_9 - chrome_43 - chrome_72 - firefox_78 @@ -109,7 +109,6 @@ steps: concurrency_group: "browserstack" concurrency_method: eager - # # BitBar tests # @@ -170,4 +169,4 @@ steps: concurrency_group: "bitbar" concurrency_method: eager env: - HOST: "localhost" # IE11 needs the host set to localhost for some reason + HOST: "localhost" # IE11 needs the host set to localhost diff --git a/test/browser/features/fixtures/browser_errors.yml b/test/browser/features/fixtures/browser_errors.yml index e3d1e46b42..77a30e4cc0 100644 --- a/test/browser/features/fixtures/browser_errors.yml +++ b/test/browser/features/fixtures/browser_errors.yml @@ -103,7 +103,7 @@ safari_16: lineNumber: 18 columnNumber: 25 -ios_12: +ios_11: handled: errorClass: 'ReferenceError' errorMessage: "Can't find variable: foo" @@ -259,6 +259,32 @@ android_8: lineNumber: 18 columnNumber: 7 +android_9: + handled: + errorClass: 'ReferenceError' + errorMessage: 'foo is not defined' + unhandled_syntax: + errorClass: 'SyntaxError' + errorMessage: "Unexpected token '!'" + lineNumber: 18 + columnNumber: 13 + file: '/unhandled/script/a.html' + unhandled_thrown: + errorClass: 'Error' + errorMessage: "bad things" + lineNumber: 18 + columnNumber: 13 + unhandled_undefined_function: + errorClass: 'ReferenceError' + errorMessage: nevergoingtoexist_notinamillionyears is not defined + lineNumber: 18 + columnNumber: 7 + unhandled_malformed_uri: + errorClass: 'URIError' + errorMessage: URI malformed + lineNumber: 18 + columnNumber: 7 + firefox_78: handled: errorClass: 'ReferenceError' From ce61cb0c089ba02b8299e9981e0f6a0a3471c59f Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Wed, 8 Oct 2025 17:40:11 +0100 Subject: [PATCH 11/15] update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ee3a6adfbe..e3cb87e79c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## [Unreleased] +## [8.7.0] - 2025-10-09 ### Added From 5b37ac5df0b934bb9c8c16a5e40fccb90bebc4ba Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Thu, 9 Oct 2025 10:25:56 +0100 Subject: [PATCH 12/15] Update CHANGELOG.md Update scope of changelog entry to electron Co-authored-by: Yousif Ahmed <74918474+yousif-bugsnag@users.noreply.github.com> --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e3cb87e79c..c79293e4e3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ ### Added -- Add `codeBundleId` config option to main process [#2577](https://github.com/bugsnag/bugsnag-js/pull/2577) +- (electron) Add `codeBundleId` config option to main process [#2577](https://github.com/bugsnag/bugsnag-js/pull/2577) ## [8.6.0] - 2025-09-25 From 4673d6175817be8711ecf6ffb56ee84eaeb12ea2 Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Thu, 9 Oct 2025 17:14:05 +0100 Subject: [PATCH 13/15] docs: :memo: update CHANGELOG.md --- CHANGELOG.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c79293e4e3..6b10119082 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ - (electron) Add `codeBundleId` config option to main process [#2577](https://github.com/bugsnag/bugsnag-js/pull/2577) +### Changed + +- Update bugsnag-cocoa to [v6.34.0](https//github.com/bugsnag/bugsnag-cocoa/releases/tag/v6.34.0) [#2571](https://github.com/bugsnag/bugsnag-js/pull/2571) + ## [8.6.0] - 2025-09-25 ### Added @@ -23,10 +27,6 @@ - (plugin-window-onerror) Guard against errors when trying to call previous handler [#2551](https://github.com/bugsnag/bugsnag-js/pull/2551) -### Dependencies - -Update bugsnag-cocoa to [v6.34.0](https//github.com/bugsnag/bugsnag-cocoa/releases/tag/v6.34.0) [#2571](https://github.com/bugsnag/bugsnag-js/pull/2571) - ## [8.5.0] - 2025-09-01 ### Added From 5549682546669ac57ee1d0c0e48621fd690a7a15 Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Fri, 10 Oct 2025 14:53:10 +0100 Subject: [PATCH 14/15] update release date --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b10119082..dc654be444 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## [8.7.0] - 2025-10-09 +## [8.7.0] - 2025-10-13 ### Added From a0d2fbdfa6126de40958832c789a54263aeaba8e Mon Sep 17 00:00:00 2001 From: Ben Wilson Date: Mon, 13 Oct 2025 09:04:01 +0100 Subject: [PATCH 15/15] fix: use common.determineVersion instead of common.getCommitId when installing cli --- scripts/generate-react-native-cli-fixture.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/generate-react-native-cli-fixture.js b/scripts/generate-react-native-cli-fixture.js index 90983cba43..010acd2520 100644 --- a/scripts/generate-react-native-cli-fixture.js +++ b/scripts/generate-react-native-cli-fixture.js @@ -22,7 +22,7 @@ if (!process.env.RCT_NEW_ARCH_ENABLED || (process.env.RCT_NEW_ARCH_ENABLED !== ' process.exit(1) } -const notifierVersion = process.env.NOTIFIER_VERSION || common.getCommitId() +const notifierVersion = process.env.NOTIFIER_VERSION || common.determineVersion() const reactNativeVersion = process.env.RN_VERSION const ROOT_DIR = resolve(__dirname, '../')