Chosen Solution

Macbook doesn’t sleep when lid closed. Tried reseting PVRAM and SMC and reinstalling OS. Replaced the screen assembly about a month ago. Replaced the battery a few weeks ago. Everything worked, it seemed, after both repairs. No water damage. Update (10/12/2020) No apps in activity monitor are preventing sleep. Here’s the response from terminal for pmset -g assertions 2020-10-13 01:32:16 -0400 Assertion status system-wide:    BackgroundTask                 0    ApplePushServiceTask           0    UserIsActive                   1    PreventUserIdleDisplaySleep    0    PreventSystemSleep             0    ExternalMedia                  0    InternalPreventDisplaySleep    1    PreventUserIdleSystemSleep     0    NetworkClientActive            0 Listed by owning process:    pid 315(UserEventAgent): [0x00001c7e000b9def] 00:00:13 BackgroundTask named: “com.apple.knowledgestore.sync” Created for PID: 320.    pid 315(UserEventAgent): [0x00001be9000b9dac] 00:02:42 BackgroundTask named: “com.apple.coreduet.sync.triggered” Created for PID: 320.    pid 143(hidd): [0x00001bd900099d9f] 00:00:00 UserIsActive named: “com.apple.iohideventsystem.queue.tickle serviceID:100002428 name:AppleHIDKeyboardEve product:Apple Internal Keyb eventType:3” Timeout will fire in 60 secs Action=TimeoutActionRelease    pid 101(powerd): [0x00001c3d00108001] 00:01:18 InternalPreventDisplaySleep named: “com.apple.powermanagement.delayDisplayOff” Timeout will fire in 41 secs Action=TimeoutActionTurnOff No kernel assertions. Idle sleep preventers: IODisplayWrangler

Have you tried going to system preferences to check your energy saver settings? (the lightbulb icon). Make sure it’s not set to never sleep.

Go to Apple menu  > System Preferences, then click Energy Saver. Make sure Never Sleep is not selected. Go to the Activity Monitor app

 and see what apps, if any need your Mac to be awake. If ”Yes” appears in the Preventing Sleep column for an app, your MacBook won’t automatically sleep while an app is running. Apps can also prevent sleep when doing certain tasks like downloading files.

Use a steel paperclip slide it along the screens bezel area on the left and right to locate the magnet in the display. Now fold down the display close enough so you can transfer its location on the uppercase (don’t go to far! You can damage things if you close it fully) Now use a rare earth magnet placing it at the location you noted with the paperclip on the uppercase. Underneath the uppercase shell is a Hall sensor which senses the magnetic flux of the magnet in the lid (or rare earth magnet you are using here) as you slide it across the uppercase passing over the location the display should go off (and then into sleep) If it fails to go off then either the locate is wrong magnet in the lid not properly installed) or the sensor has failed.