question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

react-native on android in production make error that can't read

See original GitHub issue

i got this in some part of json file in sentry server which send from
raven 3.70 android 6.0.1 Mi4 model the first one show only [native code] message vs show path and module in the simulater device

"sentry.interfaces.Exception": {
    "exc_omitted": null,
    "values": [
      {
        "stacktrace": {
          "frames": [
            {
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            },
            {
              "function": "forEach",
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            },
            {
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            },
            {
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            },
            {
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            },
            {
              "abs_path": "[native code]",
              "filename": "[native code]",
              "in_app": false
            }
          ],
          "has_system_frames": false,
          "frames_omitted": null
        },
        "mechanism": null,
        "type": "TypeError",
        "module": null,
        "thread_id": null,
        "value": "2 is not a function (evaluating 'e()')",
        "raw_stacktrace": null
      }
    ]
  },

compare with this json in simulator ( api 23, android 6.0.0 )

  "sentry.interfaces.Exception": {
    "exc_omitted": null,
    "values": [
      {
        "stacktrace": {
          "has_system_frames": false,
          "frames": [
            {
              "function": "onmessage",
              "abs_path": "http://localhost:8081/debuggerWorker.js",
              "module": "debuggerWorker",
              "in_app": false,
              "lineno": 39,
              "colno": 56,
              "filename": "/debuggerWorker.js"
            },
            {
              "function": "MessageQueue.callFunctionReturnFlushedQueue",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 11917,
              "colno": 1,
              "filename": "/index.android.bundle"
            },
            {
              "function": "guard",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 11849,
              "colno": 1,
              "filename": "/index.android.bundle"
            },
            {
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 11918,
              "colno": 8,
              "filename": "/index.android.bundle"
            },
            {
              "function": "MessageQueue.__callFunction",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 12036,
              "colno": 34,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.receiveTouches",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 19688,
              "colno": 25,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object._receiveRootNodeIDEvent",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 19626,
              "colno": 14,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.batchedUpdates",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20889,
              "colno": 18,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.batchedUpdates",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 33163,
              "colno": 13,
              "filename": "/index.android.bundle"
            },
            {
              "function": "ReactDefaultBatchingStrategyTransaction.perform",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 21685,
              "colno": 12,
              "filename": "/index.android.bundle"
            },
            {
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 19627,
              "colno": 25,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.handleTopLevel",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20727,
              "colno": 1,
              "filename": "/index.android.bundle"
            },
            {
              "function": "runEventQueueInBatch",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20716,
              "colno": 16,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.processEventQueue",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20025,
              "colno": 1,
              "filename": "/index.android.bundle"
            },
            {
              "function": "forEachAccumulated",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20690,
              "colno": 5,
              "filename": "/index.android.bundle"
            },
            {
              "function": "executeDispatchesAndReleaseTopLevel",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 19849,
              "colno": 8,
              "filename": "/index.android.bundle"
            },
            {
              "function": "executeDispatchesAndRelease",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 19838,
              "colno": 18,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.executeDispatchesInOrder",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20408,
              "colno": 1,
              "filename": "/index.android.bundle"
            },
            {
              "function": "executeDispatch",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20385,
              "colno": 17,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.invokeGuardedCallback",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 20553,
              "colno": 8,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.proxiedMethod [as touchableHandleResponderRelease]",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 9068,
              "colno": 22,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.touchableHandleResponderRelease",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 26566,
              "colno": 6,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.proxiedMethod [as _receiveSignal]",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 9068,
              "colno": 22,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor._receiveSignal",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 26792,
              "colno": 6,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.proxiedMethod [as _performSideEffectsForTransition]",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 9068,
              "colno": 22,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor._performSideEffectsForTransition",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 26876,
              "colno": 6,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.proxiedMethod [as touchableHandlePress]",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 9068,
              "colno": 22,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Constructor.touchableHandlePress",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 58914,
              "colno": 32,
              "filename": "/index.android.bundle"
            },
            {
              "function": "Object.onPress",
              "abs_path": "http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=true&minify=false",
              "module": "<unknown module>",
              "in_app": false,
              "lineno": 123937,
              "colno": 100,
              "filename": "/index.android.bundle"
            }
          ],
          "frames_omitted": null
        },
        "mechanism": null,
        "type": "TypeError",
        "module": null,
        "thread_id": null,
        "value": "a is not a function",
        "raw_stacktrace": null
      }

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:1
  • Comments:33 (9 by maintainers)

github_iconTop GitHub Comments

4reactions
benvinegarcommented, Feb 1, 2017

Hey everyone here – I would love to take this fix upstream, but I need:

  • Some actual test frames from real RN on Android data to put into tests
  • Some verification that the fix is working – I’m getting mixed answers here

Can someone help?

3reactions
khanghoangcommented, Mar 5, 2017

@benvinegar the problem is still there 😦 error hi there 2017-03-05 18-03-21

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not connect to React Native development server on ...
This error occurs because your Android Virtual Device is not connected to development server. So, check that your Android Virtual ...
Read more >
5 common errors found in a React Native app (using Expo)
When creating a mobile app with React Native, you can use Expo to streamline some complexities. Meet the most common errors and how...
Read more >
Troubleshooting - React Native
If you run into issue where executing npm run android on macOS throws the above error, try to run sudo chmod +x android/gradlew...
Read more >
Addressing common errors in React Native - LogRocket Blog
Explore common React Native errors such as "command not found" and learn about their causes and potential solutions.
Read more >
React Native Error Handling Best Practices - Rollbar
Mapping production React Native JavaScript code to your source files is slightly more complicated than in traditional JavaScript environments.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found