From b8cb5ba7081388ef38eccdf8e826747ad3a67e66 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Fri, 25 Jul 2014 09:32:14 -0400 Subject: Fixed #23083 -- Fixed runserver reloading when deleting a file. Thanks Collin Anderson for the report and hirokiky for the fix. --- django/utils/autoreload.py | 1 + 1 file changed, 1 insertion(+) (limited to 'django/utils') diff --git a/django/utils/autoreload.py b/django/utils/autoreload.py index 3ac8c1fa8e..e7df8c8938 100644 --- a/django/utils/autoreload.py +++ b/django/utils/autoreload.py @@ -91,6 +91,7 @@ def gen_filenames(only_new=False): # fail with RuntimeError: cannot mutate dictionary while iterating global _cached_modules, _cached_filenames module_values = set(sys.modules.values()) + _cached_filenames = clean_files(_cached_filenames) if _cached_modules == module_values: # No changes in module list, short-circuit the function if only_new: -- cgit v1.3