This works fine for me.
In [1]: from foo.models import Moment
In [2]: Moment.objects.create(name='the name')
Out[2]: <Moment: the name>
In [3]: Moment.objects.create(name='another name')
Out[3]: <Moment: another name>
In [4]: Moment.objects.create(name='child', parent=_)
Out[4]: <Moment: child>
In [5]: [m.name for m in Moment.objects.all()]
Out[5]: [u'the name', u'another name', u'child']
One thing to note that I had to change is that your parent
field is not null (chicken or egg). You need this:
parent = models.ForeignKey('self', null=True)
Then, delete your database file locally and syncdb
again.