diff options
| author | Max Burstein <mburst@maxburstein.com> | 2013-09-06 14:37:43 -0500 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2013-09-06 17:32:08 -0400 |
| commit | 92e89452f1aa3987cb70648e69718c6adea4b079 (patch) | |
| tree | 0d34cfaf6845996a549469e43cf495df5d4f32ae | |
| parent | 2c73ba88f25230e9e62293d25de7526d018041e8 (diff) | |
[1.6.x] Fixed #21049 -- Fixed autoreload for Python 3
Changed th system module values check to return a list.
In Python 3 it returns a dict_view which could occassionally produce
a runtime error of "dictionary changed size during iteration".
Backport of 559cb826b8 from master
| -rw-r--r-- | django/utils/autoreload.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/autoreload.py b/django/utils/autoreload.py index cc9cc1304a..6de15a2916 100644 --- a/django/utils/autoreload.py +++ b/django/utils/autoreload.py @@ -57,7 +57,7 @@ _error_files = [] def code_changed(): global _mtimes, _win filenames = [] - for m in sys.modules.values(): + for m in list(sys.modules.values()): try: filenames.append(m.__file__) except AttributeError: |
