I would get the now famous pop up “are you sure you want to shut down your computer” in the middle of typing or working. After restarting the computer would have a popup “your computer was restarted because of a problem”.
I tried every suggestion I found going down an internet rabbit hole and so here is what didn’t work and what finally worked:
Didn’t work :
- removing external devices (eg hard drives)
- not using 3rd party software (eg chrome)
- upgrading the iOS
- reinstalling the iOS
- formatting and reinstalling a clean iOS
- resetting the pram
- using an authentic Apple usb C power supply
- discharging the battery past 90% and putting to sleep for 8 hours
- running diagnostics
- replacing the power key at the Genius bar
- Booting into windows with bootcamp
I noticed as the problem got worse and happened more often, the computer wouldn’t come back on when I hit the power button. But if I closed and reopened the lid, it would sometimes trip it into powering up.
I then closed the lid and plugged it into my Work hub. My work hub is a thinkpad usbC hub that provides the monitor, keyboard mouse and power to the computer. It’s for a windows computer but works with macs as well. It is similar to a dock. As long as the lid stays closed, I was able to use the computer via the hub. I don’t know if the issue is related to the screen controller (the graphics card is still in use in this setup). It seems more likely the lid sensor that knows if the lid is open or closed. I have yet to try using the hub with the lid open.