Code review comment for lp:~julian-edwards/maas/nodegroup-on-bootimage-schema

Raphaƫl Badin (rvb) wrote :

Looks good (I've tested the migration by creating a boot image [with the db in state 0038] and then applying the migration).

This breaks a lot of tests but I'm told this is only the db migration part of the fix, an upcoming branch (or even branches) will take care of fixing up the code.

[0]

db.execute("ALTER TABLE maasserver_bootimage ALTER nodegroup_id SET NOT NULL")

fwiw, this could have been done with South's tools:

        db.alter_column(
            'maasserver_bootimage', 'nodegroup_id',
            models.ForeignKey(
                NodeGroup, null=False, editable=False, unique=False))

.. but I don't think it really matters.

review: Approve

« Back to merge proposal