Using django 10 and postgres 9.4.
After the website full setup I noticed that I cannot create new objects from my applications, default django apps like users are OK.
ran makemigrations and migrate afterwords, and when re trying it says nothing to migrate. To make it simple: When entering django shell and typing
from users.models import *
User.objects.all()
Out[3]: [<User: root>]
but :
UserProfile.objects.all()
Out[4]:
<repr(<django.db.models.query.QuerySet at 0x39b4610>) failed: django.db.utils.ProgrammingError: relation "users_userprofile" does not exist
LINE 1: ...."is_superuser", "users_userprofile"."wight" FROM "users_use...
^
UserProfile is my site users with onetoone to django.contrib.auth
class UserProfile(models.Model):
user = models.OneToOneField(User)
Thanks
makemigrations <yourappname>
? – 4140tm Aug 30 at 15:10