WindowServer will crash for me somewhat frequently (but not every time) when I disconnected my external monitors from my MBP. I have a 4k monitor plugged in via a DP=>USB-C dongle and another 1080p monitor plugged in via a HDMI=>USB-C dongle. Normally I close the lid before disconnecting...