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

not getting proper stack trace for firebase crashlytics #6381

Open
raajnadar opened this issue May 5, 2024 · 0 comments
Open

not getting proper stack trace for firebase crashlytics #6381

raajnadar opened this issue May 5, 2024 · 0 comments

Comments

@raajnadar
Copy link

Describe the bug

I tested on 2 versions of Axios and still have the problem, as per the comments from the React Native Crashalytics team the issue is due to how Axios is sending the stack trace and error-stack-parser is unable to parse it.

invertase/react-native-firebase#7282 (comment)

Stacktrace on v1.4.0

Non-fatal Exception: io.invertase.firebase.crashlytics.a: AxiosError: Request failed with status code 400
       at .<unknown>(Login POST)
       at .?anon_0_(address at index.android.bundle:1:1024957)
       at .throw((native):0:0)
       at .asyncGeneratorStep(address at index.android.bundle:1:512579)
       at ._throw(address at index.android.bundle:1:512897)
       at .tryCallOne(InternalBytecode.js:53:16)
       at .anonymous(InternalBytecode.js:139:27)
       at .apply((native):0:0)
       at .anonymous(address at index.android.bundle:1:192326)
       at ._callTimer(address at index.android.bundle:1:191323)
       at ._callReactNativeMicrotasksPass(address at index.android.bundle:1:191487)
       at .callReactNativeMicrotasks(address at index.android.bundle:1:193401)
       at .__callReactNativeMicrotasks(address at index.android.bundle:1:59173)
       at .anonymous(address at index.android.bundle:1:58315)
       at .__guard(address at index.android.bundle:1:59050)
       at .flushedQueue(address at index.android.bundle:1:58226)
       at .callFunctionReturnFlushedQueue(address at index.android.bundle:1:58082)

Stacktrace in v1.6.8

Non-fatal Exception: io.invertase.firebase.crashlytics.a: Request failed with status code 400
       at .<unknown>(Login POST)
       at .settle(address at index.android.bundle:1:1052843)
       at .onloadend(address at index.android.bundle:1:1051698)
       at .call((native):0:0)
       at .dispatchEvent(address at index.android.bundle:1:218566)
       at .setReadyState(address at index.android.bundle:1:201120)
       at .__didCompleteResponse(address at index.android.bundle:1:198857)
       at .apply((native):0:0)
       at .anonymous(address at index.android.bundle:1:200689)
       at .apply((native):0:0)
       at .emit(address at index.android.bundle:1:53578)
       at .apply((native):0:0)
       at .__callFunction(address at index.android.bundle:1:59662)
       at .anonymous(address at index.android.bundle:1:58173)
       at .__guard(address at index.android.bundle:1:59110)
       at .callFunctionReturnFlushedQueue(address at index.android.bundle:1:58131)
       at .?anon_0_(address at index.android.bundle:1:1032334)
       at .throw((native):0:0)
       at .asyncGeneratorStep(address at index.android.bundle:1:512639)
       at ._throw(address at index.android.bundle:1:512957)
       at .tryCallOne(InternalBytecode.js:53:16)
       at .anonymous(InternalBytecode.js:139:27)
       at .apply((native):0:0)
       at .anonymous(address at index.android.bundle:1:192386)
       at ._callTimer(address at index.android.bundle:1:191383)
       at ._callReactNativeMicrotasksPass(address at index.android.bundle:1:191547)
       at .callReactNativeMicrotasks(address at index.android.bundle:1:193461)
       at .__callReactNativeMicrotasks(address at index.android.bundle:1:59233)
       at .anonymous(address at index.android.bundle:1:58375)
       at .__guard(address at index.android.bundle:1:59110)
       at .flushedQueue(address at index.android.bundle:1:58286)
       at .callFunctionReturnFlushedQueue(address at index.android.bundle:1:58142)

To Reproduce

We need a new React Native project with React Native Firebase setup for crashlytics

Do you think a snack repo will be helpful? If yes I will add it

Code snippet

try {
  // API call here that should lead to error HTTP code
} catch (err: AxiosError) => {
  crashlytics().recordError(err, 'api_error');
}

Expected behavior

A stack trace with more debug details like line number, component that did the API call, etc

Axios Version

1.6.8

Adapter Version

No response

Browser

No response

Browser Version

No response

Node.js Version

20.11.0

OS

OSX 14.4.1

Additional Library Versions

"react-native": "0.71.14",
"expo": "~48.0.21",
"@react-native-firebase/app": "^19.2.2",
"@react-native-firebase/crashlytics": "^19.2.2",

Additional context/Screenshots

No response

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

No branches or pull requests

1 participant