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

Android sourcemapOutput detection broken? #772

Closed
3 of 7 tasks
muxe opened this issue Feb 19, 2020 · 9 comments · Fixed by #777
Closed
3 of 7 tasks

Android sourcemapOutput detection broken? #772

muxe opened this issue Feb 19, 2020 · 9 comments · Fixed by #777

Comments

@muxe
Copy link

muxe commented Feb 19, 2020

OS:

  • Windows
  • MacOS
  • Linux

Platform:

  • iOS
  • Android

SDK:

  • @sentry/react-native
  • react-native-sentry

SDK version: 1.3.0
react-native version: 0.59.10

Init Code:

Sentry.init({
  dsn: 'https://[email protected]/...'
});

I have following issue:

My bundle is not producing any sourcemaps and then the upload of the sourcemap fails.
I think there is an issue with forcing sourcemap output:
My default bundle command does NOT have a --sourcemap-output in.
It starts here https://github.com/getsentry/sentry-react-native/blob/master/sentry.gradle#L45
Then here https://github.com/getsentry/sentry-react-native/blob/master/sentry.gradle#L212 it tries to get the sourcemapOutput path.
So these lines wont find a sourcemapOutput https://github.com/getsentry/sentry-react-native/blob/master/sentry.gradle#L180-L186 BUT then here
https://github.com/getsentry/sentry-react-native/blob/master/sentry.gradle#L195-L198 some weird sourcemapOutput is returned.
So the script thinks there was a --sourcemap-output defined and does not force the arg, hence no sourcemap will be generated but it still expects a sourcemap to be there.

Or am I missing something?

Steps to reproduce:

  • use rn 0.59.10 and sentry 1.3.0

Actual result:

  • no sourcemap generated

Expected result:

  • a sourcemap generated
@muxe
Copy link
Author

muxe commented Feb 19, 2020

#754 (comment)

@xwartz
Copy link

xwartz commented Feb 20, 2020

cc @HazAT

@HazAT
Copy link
Member

HazAT commented Feb 21, 2020

Sorry about that, we'll take a look.

@marandaneto
Copy link
Contributor

@muxe hey, I've raised a PR #777 could you just copy/paste that part of the code and try this out? thanks :)

@muxe
Copy link
Author

muxe commented Feb 21, 2020

Thanks. I'll give it a go, but not before monday though.

I am not quite sure, but I think my --bundle-output is set but not the --sourcemap-output.
This should then still return a sourcemapOutput !== null from extractBundleTaskArguments which again leads to no args added here https://github.com/getsentry/sentry-react-native/blob/fix/sourcemaps_folder/sentry.gradle#L220-L224

But as I said this only by looking at code, I would need to run this to see how it behaves.

@marandaneto
Copy link
Contributor

@muxe sure :) but I'd say that in your case --sourcemap-output is not passed at all, this thing was implemented later than your react-native version 0.59.10, let me know your findings, thanks.

@HazAT
Copy link
Member

HazAT commented Feb 26, 2020

Fixed by #777

@HazAT HazAT closed this as completed Feb 26, 2020
@0xamogh
Copy link

0xamogh commented May 9, 2020

Still facing this issue in 1.3.7
RN version 0.62

@marandaneto
Copy link
Contributor

@amogh-jrules mind filling a bug with all the versioning + logs? thanks :)

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 a pull request may close this issue.

5 participants