Cannot read property '__error' of null
See original GitHub issueAs of version 4.6.0, Cypress has been throwing this exception during a very simple test that consists of
- Routing a request
- Logging in
- Visiting a page
- Make sure an element is displayed
This issue is reproducible with 4.7.0 version as well. It works perfectly fine in version 4.5.0. Here’s how to reproduce
- Set baseUrl in cypress.json to: https://qa1-cypress.st.dev
- Run the following test using either Cypress version 4.6.0 or later
it('Business Unit Test', () => {
cy.server()
cy.route({
method: 'GET',
url: '/Settings/GetBusinessUnits*',
response: [{
Id: 56345,
Name: 'Test BU',
OfficialName: 'Test BU',
Active: true,
Logo: null,
PostDate: null,
QbExportState: null
}],
status: 200
})
cy.request('POST', '/Auth/Login', { username: 'cydemoadmin', password: 'Test1@#$%' })
cy.visit('/#/Settings/business-units')
cy.get('.e2e-column-name').contains('Test BU').should('be.visible')
})
Here’s a screenshot of the exception stack trace
Issue Analytics
- State:
- Created 3 years ago
- Reactions:5
- Comments:8 (2 by maintainers)
Top Results From Across the Web
Uncaught TypeError: Cannot read property of null - iDiallo
This error occurs when you read a property or call a method on a null object . That's because the DOM API returns...
Read more >TypeError: Cannot read property 'value' of Null in JS
To solve the "Cannot read property 'value' of null" error, make sure that the JS script tag is placed at the bottom of...
Read more >Uncaught TypeError: Cannot read property 'value' of null
It has no problem when I execute this code, but when I'm on other part of my code this error occurs. Uncaught TypeError:...
Read more >How to deal with TypeError: cannot read properties of null
While coding in Javascript, you must have at least once received a Type Error which has the message “cannot read properties of null”....
Read more >how to fix this error Cannot read property of null ...
how to fix this error Cannot read property of null (reading 'style') ... Hi Andrew,. he's just saying that boxElement is null. That...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Same, tests that never had this now have it appearing all over the place. Cypress says it originates from our app but it doesnt seem like it is, or if it is its not appearing in a console anywhere.
Released in
4.8.0
.This comment thread has been locked. If you are still experiencing this issue after upgrading to Cypress v4.8.0, please open a new issue.