Skip to content
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

Secure coding is not enabled for restorable state (Sonoma) #28158

Closed
pavinduLakshan opened this issue Oct 27, 2023 · 19 comments
Closed

Secure coding is not enabled for restorable state (Sonoma) #28158

pavinduLakshan opened this issue Oct 27, 2023 · 19 comments
Labels
Cypress 14 Issues scoped for Cypress 14 OS: mac stage: needs information Not enough info to reproduce the issue type: bug

Comments

@pavinduLakshan
Copy link

Current behavior

Seeing the following warning when running the Cypress in headed mode in Chrome 118.

2023-10-27 15:49:35.592 Cypress[5949:37879] WARNING: Secure coding is not enabled for restorable state! Enable secure coding by implementing NSApplicationDelegate.applicationSupportsSecureRestorableState: and returning YES.

Desired behavior

Cypress should not print these kind of warnings

Test code to reproduce

Running any Cypress project on Mac OS 14 shows this warning

Cypress Version

12.5.1

Node version

v16.17.0

Operating System

MacOS 14.1

Debug Logs

No response

Other

No response

@PabloGarcia10
Copy link

Did you have any success? I'm with the same problem here..

@jennifer-shehane
Copy link
Member

@pavinduLakshan @PabloGarciaQATesting Is this causing any changes to how your tests or run or impacting the run at all?

@PabloGarcia10
Copy link

@jennifer-shehane Yes it is, I cannot run the tests or open even open cypress interface

@pavinduLakshan
Copy link
Author

In my case, it had no effect on the issue I was facing. My issue was related to a misconfigured host mapping.

@jennifer-shehane jennifer-shehane added type: bug stage: needs information Not enough info to reproduce the issue labels Nov 2, 2023
@jennifer-shehane
Copy link
Member

Can anyone provide a repo to run where this warning is showing? It's likely specific to something involved in the repo since this isn't occuring for everyone.

@glyph
Copy link

glyph commented Nov 3, 2023

@jennifer-shehane I ran across this while looking at a completely different issue beeware/toga#2188 so I thought it might be useful to note here that this is probably at least Sonoma-specific

@matt384
Copy link

matt384 commented Nov 3, 2023

Facing this issues as well, cypress was working great and now completely blocks. I tried clearing Library/Caches/Cypress... but it didn't work.

MacOS 14.0 @glyph I do believe this is sonoma specific. An unrelated app with the same issue here

@mrlonis
Copy link

mrlonis commented Nov 14, 2023

Here's an app that reproduces this: https://github.com/mrlonis/example-angular-app.

I am on Intel Mac-OS 14.1.1

@czuniga9
Copy link

czuniga9 commented Nov 16, 2023

I get this warning but it doesn't stop cypress from working. Here's a thread with details about the warning.

@obecker-csdisco
Copy link

obecker-csdisco commented Nov 20, 2023

Have the same problem, 'Cypress open' doesn't connect to Chrome anymore.

Sonoma 14.1

Cypress run still works and so does Cypess run --headed (using electron)

but

Cypess run --headed --no-exit --browser chrome

does not (same issue as Cypress open)

@obecker-csdisco
Copy link

Running with debug enabled attached output (https://github.com/cypress-io/cypress/files/13420424/debug.log))

@jennifer-shehane
Copy link
Member

@obecker-csdisco I'm not seeing the "Secure coding is not enabled for restorable state" message anywhere in your debug logs. Are you describing this same issue?

@jennifer-shehane jennifer-shehane changed the title Secure coding is not enabled for restorable state Secure coding is not enabled for restorable state (Sonoma) Nov 28, 2023
@nbouvrette
Copy link

I'm having the same issue on Cypress 13.6.0 and Node v18.18.2. I'm also on Sonoma - to reproduce:

  1. clone https://github.com/Avansai/next-multilingual
  2. npm install
  3. npm run test

@obecker-csdisco
Copy link

@obecker-csdisco I'm not seeing the "Secure coding is not enabled for restorable state" message anywhere in your debug logs. Are you describing this same issue?

Sorry, doesn't show up in the logs but in terminal.

$ cypress open
2023-12-04 08:33:25.124 Cypress[11676:59495] WARNING: Secure coding is not enabled for restorable state! Enable secure coding by implementing NSApplicationDelegate.applicationSupportsSecureRestorableState: and returning YES.

@obecker-csdisco
Copy link

Any update on this Issue ?

@jennifer-shehane
Copy link
Member

I imagine this is coming from Electron, they implemented a fix for this, but it doesn't look like they're backporting it to older versions for some reason: electron/electron#40296

We're working on an Electron update, but were not going to get up to Electron 29 quite yet.

@jennifer-shehane
Copy link
Member

I just want to note more clearly, as did the engineer at Electron, that this log message is a warning and can be ignored.

If you are encountering an error, early exit, hanging or unusual failures after this warning is displayed - that is not indicating that this warning message is the cause of the abnormal behavior in cypress. If you're encountering these situations, please open a new issue with full debug logs, a description of the problem, and a way to reproduce it and we can investigate if there is a bug causing the test run to act abnormally

@obecker-csdisco
Copy link

obecker-csdisco commented Jan 3, 2024

Not using Electron, but Chrome. Unfortunately I have no simple way to reproduce this.

My best "guess" at this point is that it is env related, as I have engineers using the same repo and being able to run cypress open successfully with chrome. Same version of MacOS, Chrome and Node

@nnaydenow
Copy link

nnaydenow commented Jun 12, 2024

Same here:
macOS: Sonoma - version 14.5
Node: v20.11.0
Cypress: 13.6.4

I've noticed that the issue appears only in Chrome and Edge but it's a problem because we need to run our tests on Chrome browser.

@jennifer-shehane jennifer-shehane added the Cypress 14 Issues scoped for Cypress 14 label Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Cypress 14 Issues scoped for Cypress 14 OS: mac stage: needs information Not enough info to reproduce the issue type: bug
Projects
None yet
Development

No branches or pull requests

10 participants