Clear the queue when a node is wiped

Clear the queue when a node is wiped.

I suspect that this is either causing or contributing to #75.
This is better than what we currently have, but not as correct as it could be. I'll merge it, but a lock on all ops involving the queue might be sensible.