Skip to content

Symbol uploads cannot carry the commit they came from (§5 of the CLI-in-JS-flows audit) #8

Open

Description

@krassx

Parked until the other audit items are closed; filed so it does not get lost. Source: §5 of the CLI-in-JS-flows audit.

What is missing

@bugsee/bundler-plugin-core already collects the build's VCS metadata — commit SHA, branch, dirty state, CI provider — in packages/bundler-plugin-core/src/vcs.ts (315 lines, with vcs-metadata in the CLI behind it). And then it has nowhere to put it: orchestrate.ts carries it only to echo it back on the result, with the comment "until the upload wire protocol has a field to put it in".

The symbol metadata POST is {uuid, version, build, hash, transform?, format?} (src/upload/presigned.rs in bugsee-cli). There is no commit field.

Why it matters

  • A JS crash cannot be joined to a commit, so there is no "which deploy introduced this".
  • No source-context-from-VCS.
  • The plugin's whole VCS collector is dead weight until this lands, and its e2e test asserts the absence — packages/instrumentation-tests/test/sourcemaps.e2e.ts pins the upload argv in full and says so: "This assertion is what will fail, deliberately, on the day one is added."

Scope — this is a wire-protocol change, not a CLI-only fix

  • appserver — accept and store the commit (plus branch / dirty / provider, if we want them) on the symbol document.
  • worker — expose it wherever a crash is joined to its symbols.
  • bugsee-cli — add the field(s) to the metadata POST and a flag or env to supply them.
  • bugsee-javascript — pass what vcs.ts already collects; update the pinned-argv e2e assertion.

Worth deciding at the same time: whether the build-registration path (bugsee-javascript#TBD, audit §6) should carry the same metadata, since Android and iOS already send commit info with a build.

🤖 Generated with Claude Code

Activity

  1. krassx commented on Nov 12, 2026

    @krassx
    ContributorAuthor

    Verified against origin/main (c7f7f12): still accurate. packages/bundler-plugin-core/src/orchestrate.ts:84 still carries the VCS metadata only to echo it back ("until the upload wire protocol has a field to put it in").

    No repo-side slice is doable on its own: the only change in this repo is passing the collected values to the CLI and updating the pinned-argv assertion in sourcemaps.e2e.ts. Both depend on bugsee-cli first accepting a commit flag/env and appserver accepting and storing the field. Passing an unknown flag now would break the upload.

    Needed before work here:

    1. Owner decision: which fields go on the wire (commit, and optionally branch / dirty / CI provider), and whether the build-registration path (audit section 6) carries the same metadata.
    2. appserver: accept and store the fields on the symbol document. worker: expose them where a crash is joined to its symbols.
    3. bugsee-cli: add the field(s) to the metadata POST (src/upload/presigned.rs) plus a flag or env to supply them.

    Once the CLI flag name is known, the bugsee-javascript slice is small. Opening no PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions