BLUF & KUDOS: it was a loose cable; reseating the connector fixed the issue.
Got an old yet working MacBookPro8,1. Wanted to use it to experiment with OLP (OpenCore Legacy Patcher). Also wanted to clean its internals from dust and rubbish, especially the fan. So I followed MacBook Pro 13" Unibody Late 2011 Fan Replacement and cleaned its internals up. Then left it a few weeks – no hurry regarding OLP.
First try with OLP failed, so I wiped the disk and reinstalled High Sierra. Then found out closing the lid didn’t sleep the Mac anymore. Tried everything listed in Fixed: MacBook not sleeping when the lid is closed and then some. To no avail. Must be hardware related, right. Got a bit anxious when reading Beating Apple’s secret lid angle sensor calibration with custom tool and Lid sensor calibration.
Decided to reopen the Mac, and there it was. Turns out it was a loose cable. To be specific: open the bottom cover and orient so you are looking at the machine so the battery is to the bottom right. The cable that controls the battery indicator lights and sleep sensor arises from the top right of the battery and inserts into the motherboard via a small square cable. Reseating the connector fixed the issue.
***
***
crwdns2934105:0crwdne2934105:0
crwdns2934113:0crwdne2934113:0
crwdns2915270:0crwdne2915270:0
crwdns2889612:0crwdne2889612:0
0
crwdns2942205:01crwdne2942205:0
FYI on a 17" the sensor cable is on the lower left of the logic board when the laptop bottom is open and you have the battery facing toward you. It's a very small ribbon cable that is easy for a tech to miss when reassembling things since it tends to curl under the board when you reseat it. This is the opposite side from the battery indicator LEDs.
crwdns2934271:0crwdnd2934271:0 Okim Selim crwdne2934271:0