python_2_unicode_compatible error

后端 未结 6 783
走了就别回头了
走了就别回头了 2020-12-06 10:22

I\'ve models.py as follows,

from django.contrib.auth.models import User
from django.db import models
from django.utils.encoding import python_2_         


        
6条回答
  •  失恋的感觉
    2020-12-06 10:55

    I ran into this issue when I wanted to use Django for Graphite. Turns out I had Django 1.3 installed and my Graphite version was breaking with Django > 1.5, so installing the latest version of the 1.4 branch fixed the problem:

    sudo pip install --upgrade 'Django<1.5'
    

提交回复
热议问题