heo
heo

Reputation: 156

Django 1.9.1 - make migrations can't detect changes

I have Django 1.9.1 installed:

>>> django.__version__
'1.9.1'

And I had my model defined in main.models:

from __future__ import unicode_literals
from django.db import models

class Collection:
    name = models.CharField(max_length=1024)
    desc = models.TextField()
    snap = models.ImageField()
    f = models.FileField()

    def __str__(self):
        return self.name;

And I had already added "main" to INSTALLED_APPS in settings:

INSTALLED_APPS = [
    'main',
    ... # Other Django stuff
]

And when I run

python manage.py makemigrations

I get the following:

➜ python manage.py makemigrations
No changes detected

I've searched through the internet and it seems like no one has encountered a problem like this... Any help will be greatly appreciated!! Thanks!

Upvotes: 0

Views: 46

Answers (1)

Daniel Roseman
Daniel Roseman

Reputation: 599480

The Connection class needs to inherit from models.Model.

Upvotes: 2

Related Questions