Skip to content
Browse files

fixed circular import

  • Loading branch information...
1 parent e9e800e commit d1a7a7c9771892194f37d61dc7f0a2be23227c26 @dhatch committed
Showing with 3 additions and 1 deletion.
  1. +3 −1 tastypie/
4 tastypie/
@@ -7,7 +7,6 @@
from tastypie.bundle import Bundle
from tastypie.exceptions import ApiFieldError, NotFound
from tastypie.utils import dict_strip_unicode_keys
-from tastypie.resources import ModelResource
@@ -493,6 +492,9 @@ def to_class(self):
if not isinstance(, basestring):
if isinstance(, dict):
# we're expected to return a functioning resource class
+ # import is here because at top it creates a circular import to
+ # resources
+ from tastypie.resources import ModelResource
self._to_class = ModelResource
self._to_class =

0 comments on commit d1a7a7c

Please sign in to comment.
Something went wrong with that request. Please try again.