GithubHelp home page GithubHelp logo

Comments (15)

a7ul avatar a7ul commented on May 28, 2024

Hi @Paradox-AT . The example code at https://github.com/master-atul/react-native-exception-handler-example seems to work as expected. Can you please recheck your configuration or can you see what you have missed from the example.

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

Hello @master-atul, I was trying to use that example but while building I am getting the following error:

:rn-test-exception-handler:compileReleaseJavaWithJavac
:rn-test-exception-handler:compileReleaseJavaWithJavac - is not incremental (e.g. outputs have
changed, no previous execution, etc.).
C:\Users\aayush.thakur\Desktop\react-native-exception-handler-example\node_modules\rn-test-exception-handler\android\src\main\java\com\masteratul\rn\testexception\RnTestExceptionHandlerPackage.java:19: error: method does not override or implement a method from a supertype
    @Override
    ^
1 error
:rn-test-exception-handler:compileReleaseJavaWithJavac FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':rn-test-exception-handler:compileReleaseJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

So I figured that there is some problem with the test package so I created my own package for throwing the exception. But still, it was not working as expected. So I tried digging into your implementation and found that even if I am setting the handler by myself it was not working for me.

It might be a problem with react-native so I also raised an issue there: facebook/react-native#19784

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

BTW, this is my dev env conf:

Environment:
OS: Windows 10
Node: 8.11.2
Yarn: 1.6.0
npm: 6.0.0
Watchman: Not Found
Xcode: N/A
Android Studio: Version 3.1.0.0 AI-173.4819257

Packages: (wanted => installed)
react: 16.3.1 => 16.3.1
react-native: 0.55.4 => 0.55.4

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

Interesting. Seems like the error was in rn-test-exception-handler package. Have fixed the issue. Everything should work normally now. Please install the latest version of rn-test-exception-handler.
PS: The issue was not in the react-native-exception-handler package.

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

Take a pull in the example repo
do yarn install
and run it as usual

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

If you still face issue. Please re open the issue. Thanks for reporting. !

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

screenshot_1529334275

After updating the project I am able to build it but still, I am getting the error in those red boxes.

Also, I looked into your code and tried to implement it by myself but still I am having the same issues.

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

This is the expected behavior. the rn-test-exception handler when in development mode will throw native errors to red boxes. Only in bundled production mode... the red boxes will be replaced. Can you try it in bundled production mode react-native run-ios --configuration Release

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

or react-native run-android --variant=release for android. You ll need to make sure you setup your project with release mode enabled. https://facebook.github.io/react-native/docs/signed-apk-android.html

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

I have updated the https://github.com/master-atul/react-native-exception-handler-example to build in production mode. You can check the latest here: https://github.com/master-atul/react-native-exception-handler-example

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

So it works in production mode..!

Hey, can you point me to the documentation for the native error handler?
Thanks..!

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

Its all there in the README.md of https://github.com/master-atul/react-native-exception-handler/

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

I am not talking about the documentation your module, I'm asking about the documentation from where you implemented your module i.e NativeModules.ReactNativeExceptionHandler.setHandlerforNativeException()

from react-native-exception-handler.

a7ul avatar a7ul commented on May 28, 2024

There is no such documentation. Its a simple unhandled exception handler found in Java/android/ios.

from react-native-exception-handler.

Paradox-AT avatar Paradox-AT commented on May 28, 2024

Okay... will look into it. Thanks

from react-native-exception-handler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.