I think (&hope) I found the problem.
I tried to trace how your plugin stores the thumbs images reference values (very smart by the way). And found that on some cases (can't tell when), the values are not stored, and an invalid (broken) reference is stored (to an none exist post id). and while you try re-upload the image the values stays the same and not changed.
So what I've done to fix this, is moving just one line of code, as follow..
on public function set_thumbnail, add the following line, just after where you get the thumbnail_id:
You could also remove that line where it is now, few lines below, but it isn't a must.
Hope that helps.