question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ImportError: cannot import name 'PasswordResetSerializer' (circular import)

See original GitHub issue

Because of this commit: https://github.com/Tivix/django-rest-auth/commit/dd6db3563f9205e4a42d171f25948cc110e13b8b I cannot import and extend any serializer.

In my project, i extend PasswordResetSerializer to overrideget_email_options. Now, a circular import is created because of that commit.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:4
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
maxim-khtcommented, Mar 6, 2017

Fixed in latest version.

1reaction
Gagarocommented, Feb 23, 2017

I ha ve the same issue. I have a custom USER_DETAILS_SERIALIZER and I extend PasswordResetSerializer. This results in a circular import.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ImportError: cannot import name '...' from partially initialized ...
I cannot have a file named retrying.py that is using the retrying package. ... error with the message "most likely due to a...
Read more >
"Circular Import Error" when separating Serializers into ...
ImportError : cannot import name 'MatchSerializer' from partially initialized module 'app.serializers.match' (most likely due to a circular ...
Read more >
How to Fix : “ImportError: Cannot import name X” in Python?
You can solve the “ ImportError : Cannot import name X” Error by resolving the circular dependencies. You can do that either by...
Read more >
cannot import name '...' from partially initialized module ...
Django : ImportError : cannot import name '. ... (most likely due to a circular import ) [ Beautify Your Computer : http......
Read more >
Django, ImportError: cannot import name Celery ... - YouTube
Django : Django, ImportError : cannot import name Celery, possible circular import ?
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found