Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Unified Diff: pkg/analyzer/lib/file_system/physical_file_system.dart

Issue 2660703002: Filter out 'FileSystemException: Failed to watch path' from _PhysicalFolder.changes. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/file_system/physical_file_system.dart
diff --git a/pkg/analyzer/lib/file_system/physical_file_system.dart b/pkg/analyzer/lib/file_system/physical_file_system.dart
index 411d0d1a6d9961a54502e8588993cb62c1ec2a8f..b190c1bf9a45cd6946163b89c2f89df94d814597 100644
--- a/pkg/analyzer/lib/file_system/physical_file_system.dart
+++ b/pkg/analyzer/lib/file_system/physical_file_system.dart
@@ -226,7 +226,9 @@ class _PhysicalFolder extends _PhysicalResource implements Folder {
_PhysicalFolder(io.Directory directory) : super(directory);
@override
- Stream<WatchEvent> get changes => new DirectoryWatcher(_entry.path).events;
+ Stream<WatchEvent> get changes => new DirectoryWatcher(_entry.path)
+ .events
+ .handleError(() {}, test: (error) => error is io.FileSystemException);
/**
* Return the underlying file being represented by this wrapper.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698