Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include business platform ID in bugsnag info #5136

Merged
merged 1 commit into from
Jan 7, 2025
Merged

Conversation

amcaplan
Copy link
Contributor

@amcaplan amcaplan commented Dec 22, 2024

WHY are these changes introduced?

Adds support for tracking business platform IDs in error reporting metadata, enabling better error tracking and debugging capabilities for business platform related issues.

WHAT is this pull request doing?

Adds business_platform_id to the list of app keys that are collected and included in error reporting metadata.

How to test your changes?

  1. Trigger an error in an app that includes a business platform ID
  2. Verify that the error report in bugsnag includes the business platform ID in the metadata

Measuring impact

How do we know this change was effective? Please choose one:

  • Existing analytics will cater for this addition

Checklist

  • I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • I've considered possible documentation changes

Copy link
Contributor

We detected some changes at packages/*/src and there are no updates in the .changeset.
If the changes are user-facing, run "pnpm changeset add" to track your changes and include them in the next release CHANGELOG.

Copy link
Contributor

github-actions bot commented Dec 22, 2024

Coverage report

St.
Category Percentage Covered / Total
🟡 Statements
75.3% (-0.02% 🔻)
8843/11743
🟡 Branches
70.55% (-0.04% 🔻)
4291/6082
🟡 Functions
75.21% (+0.01% 🔼)
2315/3078
🟡 Lines
75.85% (-0.02% 🔻)
8360/11022
Show new covered files 🐣
St.
File Statements Branches Functions Lines
🟢
... / add-uid-to-extension-toml.ts
88% 83.33% 100% 100%

Test suite run success

1994 tests passing in 902 suites.

Report generated by 🧪jest coverage report action from d5c7503

@amcaplan amcaplan force-pushed the report-BP-id-to-analytics branch from 39bfdc6 to 4e108fc Compare January 6, 2025 13:55
@amcaplan amcaplan force-pushed the report-BP-id-to-bugsnag branch from 54b4080 to d5c7503 Compare January 6, 2025 13:56
Copy link
Contributor

github-actions bot commented Jan 6, 2025

Differences in type declarations

We detected differences in the type declarations generated by Typescript for this branch compared to the baseline ('main' branch). Please, review them to ensure they are backward-compatible. Here are some important things to keep in mind:

  • Some seemingly private modules might be re-exported through public modules.
  • If the branch is behind main you might see odd diffs, rebase main into this branch.

New type declarations

We found no new type declarations in this PR

Existing type declarations

packages/cli-kit/dist/public/node/monorail.d.ts
@@ -16,6 +16,7 @@ export interface Schemas {
             env_plugin_installed_all?: Optional<string>;
         };
         public: {
+            business_platform_id?: Optional<number>;
             partner_id?: Optional<number>;
             command: string;
             project_type?: Optional<string>;
packages/cli-kit/dist/public/node/plugins.d.ts
@@ -16,7 +16,7 @@ import { Config, Interfaces } from '@oclif/core';
  * @returns A dictionary of plug-in names to the response from the hook.
  */
 export declare function fanoutHooks<TPluginMap extends HookReturnsPerPlugin, TEvent extends string & keyof TPluginMap>(config: Interfaces.Config, event: TEvent, options: TPluginMap[typeof event]['options'], timeout?: number): Promise<Partial<TPluginMap[typeof event]['pluginReturns']>>;
-type AppSpecificMonorailFields = PickByPrefix<MonorailEventPublic, 'app_', 'project_type' | 'api_key' | 'partner_id'> & PickByPrefix<MonorailEventPublic, 'cmd_extensions_'> & PickByPrefix<MonorailEventPublic, 'cmd_scaffold_'>;
+type AppSpecificMonorailFields = PickByPrefix<MonorailEventPublic, 'app_', 'project_type' | 'api_key' | 'partner_id' | 'business_platform_id'> & PickByPrefix<MonorailEventPublic, 'cmd_extensions_'> & PickByPrefix<MonorailEventPublic, 'cmd_scaffold_'>;
 type AppSpecificSensitiveMonorailFields = PickByPrefix<MonorailEventSensitive, 'app_'>;
 export interface HookReturnsPerPlugin extends HookReturnPerTunnelPlugin {
     public_command_metadata: {

Base automatically changed from report-BP-id-to-analytics to main January 7, 2025 19:49
@amcaplan amcaplan added this pull request to the merge queue Jan 7, 2025
Merged via the queue into main with commit 0401f70 Jan 7, 2025
27 checks passed
@amcaplan amcaplan deleted the report-BP-id-to-bugsnag branch January 7, 2025 19:56
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