I couldn't reproduce your issue, but I've put some thought into this and have a theory about why this issue is happening.
In version:1.0.7 I made some changes to saved factory ID numbers. It could be possible that one of the new IDS overlapped with something from the old system, causing an invalid factory.
Can you try to reproduce your issue again in a new sandbox world? It's likely that this is just an artifact of bad migration scripts on my part, and if so then the problem would go away on its own.
You can try /give-lost-factory-buildings to get the old buildings back. If the command doesn't work, send me your save and I can fix it manually.