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.

Fails due to Uncaught TypeError: Cannot read property 'native' of undefined

See original GitHub issue

I haven’t made any changes to my projects except running yarn install, but now I can’t run any tests using Cucumber, while normal Cypress tests run fine.

I tested creating the Google example files and get the same error.

An uncaught error was detected outside of a test: Uncaught TypeError: Cannot read property ‘native’ of undefined.

Here’s the full error log; ` Running: Google.feature (1 of 1)

  1. An uncaught error was detected outside of a test

0 passing (193ms) 1 failing

  1. An uncaught error was detected outside of a test: Uncaught TypeError: Cannot read property ‘native’ of undefined

This error originated from your test code, not from Cypress.

When Cypress detects uncaught errors originating from your test code it will automatically fail the current test.

Cypress could not associate this error to any specific test.

We dynamically generated a new test to display this failure. at Object.<anonymous> (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:59549:35) at Object.361…/caller.js (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:59835:4) at o (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:265) at http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:316 at Object.360…/lib/async (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:59533:13) at o (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:265) at http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:316 at Object.<anonymous> (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:16149:16) at Object.178.bluebird (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:16155:4) at o (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:265) at http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:316 at Object.177…/formatter/builder (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:15896:26) at o (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:265) at http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:316 at Object.206…/cli (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:18507:12) at o (http://localhost:35739/__cypress/tests?p=cypress/integration/Google.feature-026:1:265) `

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:6
  • Comments:22

github_iconTop GitHub Comments

9reactions
lgandeckicommented, Apr 16, 2020

Looks like the issue happens since this change in browserify resolve

https://github.com/browserify/resolve/commit/535ec22acf6d5cc4fa3665ab6dbb6755519e6deb#diff-688ede0ee2da1fa3d89f2fc485f39273R8

typeof fs.realpath.native === 'function' ? fs.realpath.native : fs.realpath;

fs.realpath is undefined

I’m digging into how to pinpoint that version to an older versoin for us or if there is something else we can do

4reactions
lgandeckicommented, Apr 17, 2020

🎉 This issue has been resolved in version 2.3.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Read more comments on GitHub >

github_iconTop Results From Across the Web

firebase - TypeError: Cannot read property 'native' of undefined
It gives the following error: TypeError: Cannot read property 'native' of undefined. I have searched a lot, but couldn't solve it. Please help....
Read more >
TypeError: Cannot read property 'native' of undefined #968
I use this module in a web project with node v10.16.0, npm 6.9.0, vue 2.9.6, and got an error when start the website:...
Read more >
Uncaught TypeError : Cannot read properties of undefined
The error clearly says that it is Undefined, which means the variable might be declared or used. Still, there is no value associated...
Read more >
What is "TypeError: Cannot read property 'state' of undefined"?
The error message says that you don't have the state property on an undefined object. To decode this, we have to understand the...
Read more >
How to Read React Errors (fix 'Cannot read property of ...
This error usually means you're trying to use .map on an array, but that array isn't defined yet. That's often because the array...
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