Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash when watched file is missing #30

Open
lieryan opened this issue Sep 15, 2014 · 0 comments
Open

Crash when watched file is missing #30

lieryan opened this issue Sep 15, 2014 · 0 comments

Comments

@lieryan
Copy link

lieryan commented Sep 15, 2014

Some text editors delete or moves a file before saving the edited file. autonose occasionally crash when it tries to detect modification time while the file is temporarily deleted.

Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 763, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/path/to/autonose/shared/state.py", line 158, in process_events_forever
    self._process_changes(new_events)
  File "/path/to/autonose/shared/state.py", line 168, in _process_changes
    map(self._process_change, changes)
  File "/path/to/autonose/shared/state.py", line 201, in _process_change
    map(self._inspect, existing)
  File "/path/to/autonose/shared/state.py", line 268, in _inspect
    self._check_for_change(rel_path)
  File "/path/to/autonose/shared/state.py", line 279, in _check_for_change
    if file_state.stale():
  File "/path/to/autonose/shared/file_state.py", line 24, in stale
    return self._get_modtime() != self.modtime
  File "/path/to/autonose/shared/file_state.py", line 21, in _get_modtime
    return os.stat(file_util.absolute(self.path)).st_mtime
OSError: [Errno 2] No such file or directory: '/path/to/project/tests.py'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant