diff --git a/django/db/models/loading.py b/django/db/models/loading.py
index e07aab4..64a0e8f 100644
|
a
|
b
|
class AppCache(object):
|
| 72 | 72 | self.nesting_level += 1 |
| 73 | 73 | try: |
| 74 | 74 | models = import_module('.models', app_name) |
| 75 | | except ImportError: |
| | 75 | except ImportError, e: |
| 76 | 76 | self.nesting_level -= 1 |
| 77 | 77 | if can_postpone: |
| 78 | 78 | # Either the app has no models, or the package is still being |
| … |
… |
class AppCache(object):
|
| 80 | 80 | # We will check again once all the recursion has finished (in |
| 81 | 81 | # populate). |
| 82 | 82 | self.postponed.append(app_name) |
| | 83 | if str(e).startswith("cannot import name"): |
| | 84 | raise |
| 83 | 85 | return None |
| 84 | 86 | self.nesting_level -= 1 |
| 85 | 87 | if models not in self.app_store: |