Fixed #23556 -- Raise a more meaningful error message when migrations refer to an unavailable node

https://code.djangoproject.com/ticket/23556
I think using a `KeyError` here is fine, but I agree that consistently raising something like a `NodeNotFoundError` (e.g. instead of `ValueError` in `MigrationGraph.forwards_plan()`) is a good idea.