Code Monkey home page Code Monkey logo

filemonitor's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

filemonitor's Issues

windows执行报错

环境:win10 +py2
报错如下:
[16:03:42]:Please enter a directory:E:\tools\xxxx\example
[16:03:54]:Unnecessary directory:"E:\tools\xxxx\example"
[16:03:58]:Display directory changes(y or n):y
[16:04:00]:FileMonitor is running...
[16:04:11]:file modified:E:\tools\xxxx\example\test.txt
[16:04:21]:file deleted:E:\tools\xxxxa\example\test.txt
Exception in thread Thread-1:
Traceback (most recent call last):
File "E:\Python\Python27\lib\threading.py", line 801, in __bootstrap_inner
self.run()
File "E:\Python\Python27\lib\site-packages\watchdog\observers\api.py", line 199, in run
self.dispatch_events(self.event_queue, self.timeout)
File "E:\Python\Python27\lib\site-packages\watchdog\observers\api.py", line 368, in dispatch_events
handler.dispatch(event)
File "E:\Python\Python27\lib\site-packages\watchdog\events.py", line 330, in dispatch
_method_mapevent_type
File "fileMonitor.py", line 51, in on_created
print(time.strftime('[%H:%M:%S]:') + "\033[5;32m%s\033[0m" % "file created:{0}".format(event.src_path))
UnicodeEncodeError: 'ascii' codec can't encode characters in position 37-38: ordinal not in range(128)

mac 报错

Traceback (most recent call last):
File "filemon", line 134, in
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/api.py", line 291, in schedule
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/kqueue.py", line 443, in init
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/utils/dirsnapshot.py", line 244, in init
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/kqueue.py", line 439, in walker_callback
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/kqueue.py", line 457, in _register_kevent
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/kqueue.py", line 242, in add
File "/Users/xxxx/Documents/2.CodeAudit/FileMonitor/watchdog/observers/kqueue.py", line 327, in init
OSError: [Errno 24] Too many open files: '/Users/xxxx/Documents/6.SourceCode/php/xunruicms_v4.4.2/xunruicms/static/assets/global/img/sidebar_inline_toggler_icon_blue.jpg'

使用main.py,fileMonitor.php 可以用
fileMonitor.py filemon 就报错。

main.py有些问题修改检测不到。

我指定了一个监控目录E:\Web,这个目录的子目录的子目录下面的txt修改ctrl+s保存后检测不到文件变化。
初始状态:
image
修改后:
image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.