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

Fix: Added test-results to file watcher ignore list #18210

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

gowtham-1127
Copy link

What does it do?

Added test-results folder to the list of ignored paths of file watcher.

Why is it needed?

Fix: #18196
Users are facing issues while running E2E tests, as the server gets restarted during the tests.

How to test it?

Go to examples/getstarted
Run yarn develop
Create a new file (e.g. test-results/something.txt)
The server restart does not happen as it was happenning before

Related issue(s)/PR(s)

Issue: #18196

@strapi-cla
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

Copy link
Contributor

@innerdvations innerdvations left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, this make sense as a default ignore. But projects with e2e tests could have also just added the config admin.watchIgnoreFiles

@innerdvations innerdvations added this to the 4.14.4 milestone Oct 4, 2023
@innerdvations innerdvations added pr: chore This PR contains chore tasks (cleanups, configs, tooling...) source: cli Source is cli package labels Oct 4, 2023
@gu-stav
Copy link
Contributor

gu-stav commented Oct 4, 2023

@innerdvations I am not in favor of this change. Adding a folder like that to the ignore list feels very arbitrary to me from a user pov. For me the underlying issue is that we do not have an explicit allowList and a ignoreList instead.

Using admin.watchIgnoreFiles sounds like a good solution to me - didn't know about that one :)

@innerdvations
Copy link
Contributor

@innerdvations I am not in favor of this change. Adding a folder like that to the ignore list feels very arbitrary to me from a user pov. For me the underlying issue is that we do not have an explicit allowList and a ignoreList instead.

Using admin.watchIgnoreFiles sounds like a good solution to me - didn't know about that one :)

I was viewing it more as a general quality of life improvement the same way we add commonly ignored things that are unrelated to strapi in the default project .gitignore. It's true it would interfere if someone legitimately had a test-results folder they wanted to watch

But if we want to avoid adding more files to the ignore list, I'm also ok closing this and just improving documentation of watchIgnoreFiles instead.

@Convly Convly modified the milestones: 4.14.4, 4.14.5 Oct 9, 2023
@markkaylor markkaylor modified the milestones: 4.14.5, 4.14.6 Oct 18, 2023
@Marc-Roig Marc-Roig modified the milestones: 4.15.0, 4.15.1 Oct 23, 2023
@Marc-Roig Marc-Roig modified the milestones: 4.15.1, 4.15.2 Oct 30, 2023
@alexandrebodin alexandrebodin modified the milestones: 4.15.2, 4.15.3 Nov 3, 2023
@alexandrebodin alexandrebodin removed this from the 4.15.3 milestone Nov 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: chore This PR contains chore tasks (cleanups, configs, tooling...) source: cli Source is cli package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Strapi server watches and restarts upon file-creation outside relevant directories
9 participants