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

watch mode: use recursive fs.watch #45271

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

Conversation

MoLow
Copy link
Member

@MoLow MoLow commented Nov 1, 2022

follow up for #45098
adapting recursive file watching into watch mode

@nodejs-github-bot nodejs-github-bot added errors Issues and PRs related to JavaScript errors originated in Node.js core. needs-ci PRs that need a full CI run. labels Nov 1, 2022
@MoLow
Copy link
Member Author

MoLow commented Nov 1, 2022

CC @anonrig

Copy link
Member

@anonrig anonrig left a comment

Choose a reason for hiding this comment

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

lgtm

@anonrig anonrig added the request-ci Add this label to start a Jenkins CI on a PR. label Nov 1, 2022
@anonrig
Copy link
Member

anonrig commented Nov 1, 2022

CC @nodejs/fs

@anonrig anonrig added the fs Issues and PRs related to the fs subsystem / file system. label Nov 1, 2022
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Nov 1, 2022
@nodejs-github-bot
Copy link
Collaborator

@bricss bricss mentioned this pull request Nov 2, 2022
@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from b5f62bb to 5dbf508 Compare November 3, 2022 10:46
@MoLow MoLow added the watch-mode Issues and PRs related to watch mode label Nov 3, 2022
@MoLow
Copy link
Member Author

MoLow commented Nov 5, 2022

@anonrig do you have any idea why this might crash the CI?

Copy link
Member

@anonrig anonrig left a comment

Choose a reason for hiding this comment

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

I mostly think that due to the async nature of fs.watch is causing the errors to fail. Please add a timeout after listening

@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from 5dbf508 to 75f4a97 Compare November 5, 2022 22:04
@MoLow
Copy link
Member Author

MoLow commented Nov 5, 2022

@anonrig I have implemented your suggestions, but it is not just a test failure - the build seems to crash

@anonrig
Copy link
Member

anonrig commented Nov 7, 2022

I think you need to skip the tests for only AIX and IBMi.

@MoLow
Copy link
Member Author

MoLow commented Nov 7, 2022

I think you need to skip the tests for only AIX and IBMi.

I am just trying to figure out why the build is crashing

@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch 2 times, most recently from c0fefbe to fa63c9b Compare November 9, 2022 14:42
@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from 170cade to 2d6f225 Compare November 12, 2022 19:27
@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from 2d6f225 to 7b63ee7 Compare November 13, 2022 06:36
@MoLow
Copy link
Member Author

MoLow commented Nov 13, 2022

will handle this after #45214 since they conflict as well

@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from 6812665 to dc77925 Compare November 13, 2022 21:41
Copy link
Member

@anonrig anonrig left a comment

Choose a reason for hiding this comment

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

I believe that the issue with lib/internal/fs/recursive_watch.js should be committed separately in a different pull request. Other than that, I've added some comments. Thank you for your contribution!

test/parallel/test-fs-watch-recursive.js Outdated Show resolved Hide resolved
test/parallel/test-fs-watch-recursive.js Outdated Show resolved Hide resolved
test/parallel/test-watch-mode-files_watcher.mjs Outdated Show resolved Hide resolved
lib/internal/fs/recursive_watch.js Outdated Show resolved Hide resolved
lib/internal/fs/recursive_watch.js Outdated Show resolved Hide resolved
@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from dc77925 to 93532f3 Compare November 17, 2022 20:20
@MoLow MoLow force-pushed the watch-mode-recursive-follow-up branch from 93532f3 to 03e801d Compare November 27, 2022 22:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
errors Issues and PRs related to JavaScript errors originated in Node.js core. fs Issues and PRs related to the fs subsystem / file system. needs-ci PRs that need a full CI run. watch-mode Issues and PRs related to watch mode
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants