-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Nightmare should set a partition by default #916
Comments
Same problems here. I don't want sessions to be shared across different instances. I was trying to find the 'incognito' mode too, but no luck. |
I've been doing 'nopersist' all the time in my main config to avoid Nightmare from persisting states. I use it in integration tests where tests should be initially stateless and also independent from all other tests. |
@jekku Do you mean literally using the name |
The current behavior uses electron default, which creates a partition for storage which persists between instances. This makes sense for electron but not necessarily for primary use cases of Nightmare. This change sets the default partition to be a non-persistent partition but allows a user to opt back into persistence with simple configuration options. Fixes segment-boneyard#916
I got burned pretty hard by the fact that I am starting and stopping the browser and there is some state that is getting stored between instances and it was affecting my tests on subsequent runs.
I would like to make a PR that automatically sets a partition by default. If a user wanted to persist state between tests they could set the partition to be
paritition: 'persist: whatever'
still to override it orpartition: null
to revert to the default.Is there any reason why it would be good or should actually be set to persist between browser runs? If not I will make a PR to change it. Otherwise I may just add to the front page documentation with a tip about setting the partition to prevent this issue.
The text was updated successfully, but these errors were encountered: