@parcel/watcher is a native C++ Node module for querying and subscribing to filesystem events, used by Parcel 2. It can watch directories recursively for realtime create, update, and delete notifications, and it can query historical changes since a saved snapshot to help invalidate caches. It includes cross-platform backends for macOS, Linux, Windows, FreeBSD, and optionally Watchman.
Project status
- The repository appears actively maintained, with upstream activity as recent as 2026-06-03 and multiple tagged updates in early 2026.
- The apparent update cadence is steady patching, with updates at 2025-01-26, 2026-01-11, and 2026-01-23 (then further upstream pushes later in 2026).
AI summary generated Today
Recent updates
v2.5.6
4 months agoRelease v2.5.6 makes small build and CI adjustments. The documented intent is to harden native code compilation with stack protector flags and to fix Windows ia32 build issues.
Securityv2.5.4
4 months agov2.5.4 is a patch release focused on stability and compatibility fixes, including addressing crashes related to static initialization order fiasco (SIOF) and improving libc/watchman compatibility. It also switches glob matching from micromatch to picomatch and updates CI/build tooling.
SecurityFeaturesv2.5.1
1/26/2025v2.5.1 contains targeted reliability fixes around filesystem event handling, plus improved error handling paths. The main functional changes are new error propagation mechanisms tied to the macOS FSEvents “must scan subdirs” and “dropped events” cases, and improved regex error handling when building ignore globs.
v2.5.0
11/4/2024v2.5.0 adds support for the 32-bit ARM musl platform and introduces an npm option to build from source instead of using prebuilt binaries. The release notes also claim fixes for use-after-free and a deadlock, plus a macOS change to avoid security dialogs. The code diff shows additional, largely internal native refactors and runtime changes that are not described in the release notes.
Featuresv2.4.0
1/15/2024This release (v2.4.0) adds CommonJS support for `@parcel/watcher-wasm` in addition to the existing ESM support. The build system now generates a CJS entry and updates the published package metadata to expose a CJS `require` entry point.
Featuresv2.3.0
8/24/2023v2.3.0 adds new filesystem watching backends, specifically a kqueue backend and a WASM backend, and migrates internal callback delivery to N-API thread safe functions to better support use from multiple Node.js worker threads. It also includes a 32-bit Windows build. Overall the release is focused on expanding platform support and improving multi-thread usage, but the code diff contains additional behavioral and default-selection changes not fully captured in the release notes.
Featuresv2.2.0
7/2/2023v2.2.0 changes @parcel/watcher to load platform specific prebuilt binaries from separate packages (for example, @parcel/watcher-darwin-x64), rather than bundling binaries for all platforms inside the main package. The runtime now selects the correct binary based on process.platform and process.arch, and on Linux it also detects musl vs glibc.
BreakingFeaturesv2.1.0
1/5/2023v2.1.0 adds support for glob patterns in the `ignore` option, and updates the watcher internals to compile glob patterns into regex matchers. It also includes a Windows-focused fix intended to prevent directory locking. Overall, ignore handling behavior becomes more complex, with separate handling for literal paths vs glob-derived patterns.
Featuresv2.0.7
11/4/2022v2.0.7 updates the macOS FSEvents watcher backend to suppress duplicate events that occur when the file modification time (mtime) does not actually change. The change adds mtime tracking in the internal directory tree and uses stat and stored DirEntry mtime to decide whether to emit updates.
v2.0.6
11/2/2022v2.0.6 primarily updates the internal debounce behavior, improves macOS filesystem event handling (notably mounted file systems), and addresses a Linux segmentation fault related to inotify subscriptions. Beyond those notes, the code introduces additional behavioral changes around event coalescing, symlink/stat handling on Linux, and permission error handling on Unix platforms.
Breaking