Open math-a3k opened 6 years ago
This migration does the trick: https://github.com/math-a3k/django-ai/blob/master/misc/django_dag_0001_initial.py Though not without caveats, it will ask for a default value for the existing rows - which are none, because is an initial, so you can safely put any number.
I still can't find where the problem is exactly, if django_ai is installed as a package, Django creates the migrations "well", but inside the package it doesn't: it creates either django_dag's or the django_ai's app, pointing to each other and ending up in a circular dependency error.
The solution is copying that migration to django_dag migrations and migrate your app, that way it will go smoothly (with the "default value" caveat)
I'm developing a package with Django 1.11 which depends on django-dag.
There are 2 models in the app depending on dag:
The problem is that on a fresh install, django_dag does not ships with the initial migration and Django creates it when another migration requiring it is created.
If I ship that migration (pointing to django_dag tables) it will fail on a fresh install because it points to a non-existent one, and the migrations have to be deleted and recreated to trigger the creation of dag tables.
Have you consider including an initial migration with those tables in order to fix this kind of problems?