Skip to content

Commit

Permalink
Ignored pywatchman.SocketTimeout in Watchman autoreloader.
Browse files Browse the repository at this point in the history
Bumped minimum supported pywatchman version to 1.2.0.

These exceptions don't require checking a server status.
  • Loading branch information
blueyed authored and felixxm committed May 3, 2019
1 parent 8c5649b commit 29601bc
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 2 additions & 0 deletions django/utils/autoreload.py
Expand Up @@ -506,6 +506,8 @@ def tick(self):
self.processed_request.clear()
try:
self.client.receive()
except pywatchman.SocketTimeout:
pass
except pywatchman.WatchmanError as ex:
self.check_server_status(ex)
else:
Expand Down
3 changes: 2 additions & 1 deletion docs/ref/django-admin.txt
Expand Up @@ -888,7 +888,8 @@ If you're using Linux or MacOS and install both `pywatchman`_ and the
`Watchman`_ service, kernel signals will be used to autoreload the server
(rather than polling file modification timestamps each second). This offers
better performance on large projects, reduced response time after code changes,
more robust change detection, and a reduction in power usage.
more robust change detection, and a reduction in power usage. Django supports
``pywatchman`` 1.2.0 and higher.

.. admonition:: Large directories with many files may cause performance issues

Expand Down
2 changes: 2 additions & 0 deletions docs/releases/3.0.txt
Expand Up @@ -368,6 +368,8 @@ Miscellaneous
* The ``django-admin test -k`` option now works as the :option:`unittest
-k<unittest.-k>` option rather than as a shortcut for ``--keepdb``.

* Support for ``pywatchman`` < 1.2.0 is removed.

.. _deprecated-features-3.0:

Features deprecated in 3.0
Expand Down

0 comments on commit 29601bc

Please sign in to comment.