action-release icon indicating copy to clipboard operation
action-release copied to clipboard

"Sentry not part of build pipeline" when using action for source maps

Open codybswaney opened this issue 2 years ago • 3 comments

Github Sentry Action Release Bug Report

Hello, I'm trying to understand why sentry is saying "Sentry not part of build pipeline" when using this to create a release and upload source maps. Admittedly, our situation is specific in that we need to upload source maps without deploying the maps themselves to our production environment. Perhaps there is a better way to go here?

Appreciate any help you can provide!

Environment

Standard GitHub runners on ubuntu-latest, using v1 action

Steps to Reproduce

  1. Generate source maps
  2. Inject debugIds via sentry-cli sourcemaps inject out/_next/static
  3. Use action to create release and upload source maps
            - name: Create Sentry Release
              uses: getsentry/action-release@v1
              env:
                  SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
                  SENTRY_ORG: ${{ vars.SENTRY_ORG }}
                  SENTRY_PROJECT: ${{ vars.SENTRY_PROJECT }}
              with:
                  environment: staging
                  finalize: false
                  sourcemaps: ./out/_next/static
                  version: ${{ env.COMMIT_SHA_SHORT }}
  1. Remove sourcemaps before production deploy
  2. Production deploy initializes sentry and finalizes the release

Expected Result

Viewing errors would un-minify the javascript.

Actual Result

Sentry not part of build pipeline Read Guide Integrate Sentry into your build pipeline using a tool like Webpack or the CLI.

Screenshot 2023-07-19 at 4 21 40 PM

I can see the artifacts associated with the release in sentry as well Screenshot 2023-07-19 at 4 24 55 PM

codybswaney avatar Jul 19 '23 20:07 codybswaney

I have a similar problem. I can see the github action working as expected (no errors). Sourcemaps and js files are uploaded as expected, and are found in Source Maps > Release Bundles as per https://docs.sentry.io/platforms/javascript/guides/vue/sourcemaps/troubleshooting_js/#verify-artifacts-are-uploaded

It seems that the github action is either

  • not setting the release id in the uploaded files because they are deprecated release bundles, not newer artifact bundles https://docs.sentry.io/platforms/javascript/sourcemaps/troubleshooting_js/artifact-bundles/#artifact-bundles see #159
  • or not injecting sentryDebugIds as per https://docs.sentry.io/platforms/javascript/guides/vue/sourcemaps/troubleshooting_js/#verify-your-source-files-contain-debug-id-injection-snippets

It was tricky getting sourcemaps working to begin with. I try not to touch this stuff, so it was probably some kind of 0.0.1 release of the sentry npm modules that was not actually backwards compatible (not following semver)?

steveatkoan avatar Jul 20 '23 02:07 steveatkoan

Looking at the github action log, i see Download action repository 'getsentry/action-release@v1' (SHA: 586b62368d564f25d694ce05fcb9cf53de65ac4f) This matches the v1.3.1. release from 4 March. Latest release from is 1.4.1 from 21 April. Today is 20 Jul. So for some reason it is not pulling the latest release when the action runs...

if I hard code the version number in the github action eg getsentry/[email protected] i get the correct version, but still see the above behaviour

steveatkoan avatar Jul 20 '23 02:07 steveatkoan

Sentry support asked me to migrate from manually uploading sourcemaps to using this action. Looks like it was a bad idea, since it seems same broken than the cli tool.

Same/similar issue here. Super frustrated :(

mindrunner avatar Aug 05 '23 12:08 mindrunner