Django-ads-txt causing ImportError: cannot import name 'python_2_unicode_compatible' from 'django.utils.encoding'

61 Views Asked by At

Hi I trying to Install django-ads-txt to my Django Project.

My first step was to pip install django-ads-txt then I added in the urls path('ads.txt', include('ads_txt.urls')), when I tried to python manage.py migrate I got the following error:

from django.utils.encoding import python_2_unicode_compatible

ImportError: cannot import name 'python_2_unicode_compatible' from 'django.utils.encoding'

I tried to pip install six but the same error kept showing

My question: How to fix this error to install django-ads-txt?

0

There are 0 best solutions below