-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cypress reloads in infinite loop when calling cy.visit to http URL that upgrades to https. #25891
Comments
Thanks for opening an issue @Jsijbel. Confirmed that I can reproduce this behavior. Is there a specific version this started occurring on for you? It seems like there is a 301 and two 302's before landing back on I'll get this routed and prioritized for a fix. |
Thank your for your response and acknowledgement. |
Was curious if there was a workaround ever found for this issue? I think I am perhaps hitting a similar issues (v12.9.0) |
I am also curious about some workaround. Also having this issue (12.11.0) with an Angular app (redirects when authenticating). |
Hi, I'm having the same issue. Is there any news about this problem? or any workaround? Thank you |
I have the same problem..any news about this bug? |
We observed this unexpected looping behaviour when Cypress was running on https:// in the Chrome browser that it was driving. The server for our system under test (SPA web app) only supports the http:// protocol. When we manually removed the s in the URL bar in the Cypress-driven Chrome, it began behaving as expected again (no looping). |
As first, |
Between our tests running fine on Firefox and the comment above by @BevanR (thank you!), I'm wondering if this may be related to Chrome's recent change to use HTTPS by default. |
@flotwig - Our team is also facing the same issue. URL starts with |
Also having this issue - Chrome only |
Cypress suport only http protocol.
|
exactly same issue here on Cypress [13.5.0] |
To summarize, the issue arises only with newer versions of Chrome (it worked for me with an older version). The problem likely started with the introduction of https://blog.chromium.org/2023/08/towards-https-by-default.html. Workaround: or a more permanent workaround is here: |
Actually, I'm not using Chrome, but Microsoft Edge v120. I thought it should work as well :( |
I updated the workaround here: #25891 (comment) |
@alexsch01 Nope..... still not working with Cypress v 13.6.1 and Chrome v120 .... you can test that by adding code to the scaffolded cypress tests. |
Hi, I'd like to get some understanding on why this workaround doesn't work for people. To visit the correct URL to begin with. Is there a reason you need to visit the
|
Internal (not exposed to the Internet) company apps generally use http
|
Lets say cy.visit('http://test') - won't have the looping issue for the httpforever.com example cy.visit('http://146.190.62.39') - won't have the looping issue |
@jennifer-shehane In DevTools running in Cypress Chrome window, |
I have also issue with opening |
We're narrowing in on a solution. So will hopefully have some updates soon on this. |
UPDATEDBelow instructions works around the issue, until a proper solution is made Both PART1 and PART2 are required PART1 - in
PART2 - in cypress config
|
@alexsch01 this part of code is not working - because |
@VolodymyrDmytriukhin just tested on Linux, NodeJS 12.16.3, Cypress 10.0.0 - it works for me with chromium and electron |
@jennifer-shehane I made repo to reproduce the issue: https://github.com/alexsch01/testing |
Yah we can reproduce the issue and are working on a solution which requires some changes on the App as well as some manual changes to Chrome settings for users who have already encountered this issue to their hsts domain settings. It shouldn't cause an infinite loop for users in the future who haven't encountered it once though. Most of our team is on holiday this week however, so the solution will be delayed. |
@jennifer-shehane Thanks. I made a bug report with Chromium: https://bugs.chromium.org/p/chromium/issues/detail?id=1513507, since it could be a Chromium bug |
@alexsch01 Thanks for opening the issue. It does seem like they're not doing something correctly here. |
just FYI the issue is also present on the Chromium version < 100. |
Screen.Recording.2024-01-11.at.22.39.48.movStill not working properly |
@tudorgabriel the fix on Cypress's side isn't released yet |
I removed the 's' from https then it works for me. Thank you |
We're trying to get a release out for this today. |
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
Current behavior
When visiting a page that triggers certain redirects, the test runner keeps reloading and looping endlessly.
2023-02-21_10-39-18.mp4
Desired behavior
Not reload the test runner and follow redirects.
Test code to reproduce
Cypress Version
12.6
Node version
18.12.1
Operating System
Win 11
Debug Logs
No response
Other
No response
The text was updated successfully, but these errors were encountered: