expo / sentry-expo

MIT License
202 stars 83 forks source link

postPublish not running on android expo SDK 48 for Android #329

Closed RRaideRR closed 1 year ago

RRaideRR commented 1 year ago

Summary

Not quite sure how already closed issue (#320 #292 ) are observed - probably not so much, so that's the reason why I'm opening up this issue.

I took this sample app and updated my dependencies to match the latest Expo SDK 48 release. In addition, I'm also using the url parameter because I have my own Sentry server. The source maps are not uploaded for Android eas builds.

I can see "Upload Debug Symbols to Sentry" in my fastlane logs but not in my gradle logs.

My specific dependencies:

    "expo": "~48.0.6",
    "expo-status-bar": "~1.4.4",
    "react": "18.2.0",
    "react-native": "0.71.3",
    "sentry-expo": "~6.1.0",
    "expo-application": "~5.1.1",
    "expo-constants": "~14.2.1",
    "expo-device": "~5.2.1",
    "expo-updates": "~0.16.3",
    "@sentry/react-native": "4.13.0"

However: iOS upload works. Two minor things that I changed in comparison to your project:

I've made use of the SENTRY_AUTH_TOKEN variable I use my own sentry server. Thus, my postPublish hook looks like this:

     "hooks": {
      "postPublish": [
        {
          "file": "sentry-expo/upload-sourcemaps",
          "config": {
            "organization": "myOrg",
            "project": "expo-test",
            "url": "https://sentry.myServer.com/"
          }
        }
      ]
    },

It seems like I'm not the only one where this is happening.

Managed or bare workflow? If you have ios/ or android/ directories in your project, the answer is bare!

managed

What platform(s) does this occur on?

Android

SDK Version (managed workflow only)

48

Environment

  expo-env-info 1.0.5 environment info:
    System:
      OS: macOS 13.3
      Shell: 5.9 - /bin/zsh
    Binaries:
      Node: 18.15.0 - ~/.nvm/versions/node/v18.15.0/bin/node
      Yarn: 1.22.19 - ~/.yarn/bin/yarn
      npm: 9.5.0 - ~/.nvm/versions/node/v18.15.0/bin/npm
      Watchman: 2023.03.06.00 - /opt/homebrew/bin/watchman
    Managers:
      CocoaPods: 1.12.0 - /opt/homebrew/bin/pod
    SDKs:
      iOS SDK:
        Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1
    IDEs:
      Android Studio: 2022.1 AI-221.6008.13.2211.9619390
      Xcode: 14.2/14C18 - /usr/bin/xcodebuild
    npmPackages:
      expo: ~48.0.6 => 48.0.8 
      react: 18.2.0 => 18.2.0 
      react-native: 0.71.3 => 0.71.3 
    npmGlobalPackages:
      eas-cli: 3.8.1
    Expo Workflow: managed

Reproducible demo or steps to reproduce from a blank project

Take this sample app and update the dependencies to match the latest Expo SDK 48 release.

MaxInMoon commented 1 year ago

@RRaideRR did you find a workaround ?

RRaideRR commented 1 year ago

Nope the problem still exists.

thomasgrivet commented 1 year ago

Hello, this issue is still present and is preventing us from upgrading to SDK 48

anirudhsama commented 1 year ago

Hi, we are also facing this issue!

karbone4 commented 1 year ago

Hey, I have same issue on sdk 48

lobotomoe commented 1 year ago

Same iOS either, sdk 48.

Alex1899 commented 1 year ago

I am getting the same issue on Android, Expo sdk 48. Has anybody managed to fix this? I would really appreciate it if you could share a solution.

krystofwoldrich commented 1 year ago

Hello everyone, thank you for using the sample app it makes debugging these issues much easier.

I've updated the sample to Expo SDK 48 and reproduced the same issue.

To fix it simply bump the @sentry/react-native to the latest v4 version. Currently, that is @sentry/react-native@4.15.2.

After that, the automatic source map upload on Android will be working again.

For anyone interested this (https://github.com/getsentry/sentry-react-native/pull/2759) is the fix on the undelaying sentry-react-native package.