pyuv: adapt to 1.x API changes
This commit is contained in:
parent
36737867b1
commit
3474c0dad5
|
@ -82,12 +82,9 @@ class UvWatcher(object):
|
|||
with self.lock:
|
||||
if path not in self.watches:
|
||||
try:
|
||||
self.watches[path] = pyuv.fs.FSEvent(
|
||||
self.loop,
|
||||
path,
|
||||
partial(self._record_event, path),
|
||||
pyuv.fs.UV_CHANGE | pyuv.fs.UV_RENAME
|
||||
)
|
||||
handle = pyuv.fs.FSEvent(self.loop)
|
||||
self.watches[path] = handle
|
||||
handle.start(path, 0, partial(self._record_event, path))
|
||||
except pyuv.error.FSEventError as e:
|
||||
code = e.args[0]
|
||||
if code == pyuv.errno.UV_ENOENT:
|
||||
|
|
Loading…
Reference in New Issue