This crash happened when placing down waterways. I'm currently doing K2+SE if that has any relevance.
https://imgur.com/y1iBjVw
The mod Cargo Ships (0.0.58) caused a non-recoverable error.
Please report this error to the mod author.
Error while running event cargo-ships::on_built_entity (ID 6)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
[C]: in function 'index'
__cargo-ships/control.lua:87: in function <cargo-ships/control.lua:14>
Edit: Tested with Creative Mod and Cargo Ships only and got the same crash.