Edit: There seems to be some confusion about what I\'m asking. That model is for the Postgres view that I created in migration 0009. I was under the impress
Django does create a migration for each newly added table in your app regardless of whether it's a managed model or not. However there is a very important and subtle difference when you use the managed=False
setting. The resultant migration is a dummy entry. It does not execute any SQL at all.
To confirm this add a new model that is unmanaged
class Dummy(models.Model):
something = models.IntegerField()
class Meta:
managed = False
now when you do makemigrations
followed by sqlimigrate *myapp* *migration_number*
you will see that it doesn't produce any sql.
If on the other hand, you do find that Django is trying to create a table for you, that usually means that you had the same model in existence earlier but at the time the model was managed. To confirm this, search your migrations
folder for VirtualTotal
which is the name of the model in question.