From 449243af4e4e0759fa89e1cb342f27df57326b71 Mon Sep 17 00:00:00 2001 From: Jinjing <6427696+AmethystLiang@users.noreply.github.com> Date: Sun, 15 Nov 2026 14:16:10 -0800 Subject: [PATCH] fix(watchers): apply Library exclusions where the watcher receives a subscribe Keeps the existing Parcel options cast untouched. --- .../parcel-watcher-process-entry.ts | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/main/ipc/filesystem/watcher-process/parcel-watcher-process-entry.ts b/src/main/ipc/filesystem/watcher-process/parcel-watcher-process-entry.ts index ffc5124af70..245e4fcacc4 100644 --- a/src/main/ipc/filesystem/watcher-process/parcel-watcher-process-entry.ts +++ b/src/main/ipc/filesystem/watcher-process/parcel-watcher-process-entry.ts @@ -146,10 +146,7 @@ function main(): void { ) } }, - // The host sends the canonical root; decide exclusions here, off Electron main. - withMacosProtectedWatchExclusions(dir, opts, { - realpath: realpathSync.native - }) as ParcelWatcher.Options + opts as ParcelWatcher.Options ) } finally { activeSubscriptionCrawlId = null @@ -222,7 +219,15 @@ function main(): void { if (message.op === 'subscribe') { subscriptions.set( message.id, - handleSubscribe(message.id, message.dir, message.opts, message.delivery) + handleSubscribe( + message.id, + message.dir, + // The host sends the canonical root; decide exclusions here, off Electron main. + withMacosProtectedWatchExclusions(message.dir, message.opts, { + realpath: realpathSync.native + }), + message.delivery + ) ) return }