Merge pull request #11353 from kvuorine/fwknop-fixes
[feed/packages.git] / lang / python / django1 / patches / 001-load-byte-compiled-db-migrations.patch
1 --- a/django/db/migrations/loader.py
2 +++ b/django/db/migrations/loader.py
3 @@ -106,7 +106,7 @@ class MigrationLoader(object):
4 # Scan for .py files
5 migration_names = set()
6 for name in os.listdir(directory):
7 - if name.endswith(".py"):
8 + if name.endswith(".py") or name.endswith(".pyc"):
9 import_name = name.rsplit(".", 1)[0]
10 if import_name[0] not in "_.~":
11 migration_names.add(import_name)