From 39c812643f0380b2cc7189d986db764facc98fad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Jos=C3=A9=20Arboleda?= Date: Fri, 27 Mar 2020 01:17:54 -0500 Subject: [PATCH 1/3] doc: clarify docs fs.watch exception may be emitted Fixes: https://github.com/nodejs/node/issues/29894 --- doc/api/fs.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 74c73e972086f6..552195f65d44be 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -3815,10 +3815,10 @@ to be notified of filesystem changes. * On Aix systems, this feature depends on [`AHAFS`][], which must be enabled. If the underlying functionality is not available for some reason, then -`fs.watch` will not be able to function. For example, watching files or -directories can be unreliable, and in some cases impossible, on network file -systems (NFS, SMB, etc), or host file systems when using virtualization software -such as Vagrant, Docker, etc. +`fs.watch` will not be able to function (may an exception will be thrown). +For example, watching files or directories can be unreliable, and in some +cases impossible, on network file systems (NFS, SMB, etc), or host file systems +when using virtualization software such as Vagrant, Docker, etc. It is still possible to use `fs.watchFile()`, which uses stat polling, but this method is slower and less reliable. From 69d061b9c6e6eb4338d472b9a13390848bde31e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Jos=C3=A9=20Arboleda?= Date: Fri, 27 Mar 2020 17:22:53 -0500 Subject: [PATCH 2/3] fixup --- doc/api/fs.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 552195f65d44be..1833c323b05fe6 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -3815,7 +3815,7 @@ to be notified of filesystem changes. * On Aix systems, this feature depends on [`AHAFS`][], which must be enabled. If the underlying functionality is not available for some reason, then -`fs.watch` will not be able to function (may an exception will be thrown). +`fs.watch` will not be able to function (an exception may be thrown). For example, watching files or directories can be unreliable, and in some cases impossible, on network file systems (NFS, SMB, etc), or host file systems when using virtualization software such as Vagrant, Docker, etc. From 9c5e8fac0c85ba66b17c7b40bbf7249856335219 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Jos=C3=A9=20Arboleda?= Date: Tue, 31 Mar 2020 04:58:30 -0500 Subject: [PATCH 3/3] fixup --- doc/api/fs.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 1833c323b05fe6..b53169e9f3183e 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -3815,10 +3815,10 @@ to be notified of filesystem changes. * On Aix systems, this feature depends on [`AHAFS`][], which must be enabled. If the underlying functionality is not available for some reason, then -`fs.watch` will not be able to function (an exception may be thrown). +`fs.watch()` will not be able to function and may thrown an exception. For example, watching files or directories can be unreliable, and in some -cases impossible, on network file systems (NFS, SMB, etc), or host file systems -when using virtualization software such as Vagrant, Docker, etc. +cases impossible, on network file systems (NFS, SMB, etc) or host file systems +when using virtualization software such as Vagrant or Docker. It is still possible to use `fs.watchFile()`, which uses stat polling, but this method is slower and less reliable.