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.

`undefined (reading 'undefined')` on cypress_runner.js

See original GitHub issue

Current behavior

When running on cypress@9.3.1, there is an issue on cypress_runner.js - Cannot read properties of undefined (reading 'undefined'). It happens on https://github.com/cypress-io/cypress/blob/8355e5d8ec35411a6935687c9c91540dd32cf7f4/packages/driver/src/cy/navigation.ts#L29

image

This error usually happens on cy.go('back'). Failing tests on Cypress dashboard - https://dashboard.cypress.io/projects/oqk3fk/runs/4680/overview

Desired behavior

No undefined error messages

Test code to reproduce

it(‘should return to previous page’, function () { cy.go(‘back’) })

Cypress Version

9.3.1

Other

No response

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
Hypercubedcommented, Jan 28, 2022

@thedoublejay Thank you for posting this… helped me narrow down an issue that was really bothering us. For Cypress team I’d like to point out that this error includes the message “The following error originated from your application code, not from Cypress.” which really lead us astray!!

1reaction
emilyrohrboughcommented, Apr 7, 2022

We have a test that navigate between 2 pages and we assert about keeping some query params in the URL after cy.go(‘back’).

After upgrade cypress this test stoped working. go back seems not working well, sometimes it throws this error, sometimes it does not go back, and rarely it works as it should.

It sounds like the behavior you are describing is a bit unrelated to the original issue. @mr-short put #20948 out to fix the error reported. If this change doesn’t resolve your issues, can you open a new issue with a reproducible example we can use to narrow down the issue you are seeing?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cypress TypeError: Cannot read properties of undefined ...
TypeError: Cannot read properties of undefined (reading 'uid') at Object. statSync (C:\Windows\SysWOW64\config\systemprofile\AppData\Local\ ...
Read more >
cypress-io/cypress - Gitter
Hi, running into an issue with a test I'm writing. When I visit the page, in the desktop app it redirects to a...
Read more >
Cypress - Cannot read property 'add' of undefined - Laracasts
Hi I'm new to testing with Cypress and wading my way through but have come across an error I can't seem to resolve....
Read more >
Error Messages | Cypress Documentation
This message means that Cypress encountered an error when compiling and/or bundling your test file. Cypress automatically compiles and bundles your test code...
Read more >
Cannot read properties of undefined (reading 'length')
### Current behavior Javascript error is thrown when using Cypress together wit…h Newrelic agent running on the browser. Error is: ``` Unable to ......
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