Repository navigation
Article: Find What Wakes a Windows PC With Get-WinEvent - #525
HeyItsGilbert merged 3 commits into
Conversation
✅ Deploy Preview for powershellorg ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
🟡 Changes recommended
The missing November archive _index.md causes the required validate:articles CI step to fail.
3 open issues
What changed in this PR
Adds a community troubleshooting article for Windows administrators, implementing the pitch in #428 with a PowerShell function for examining sleep and wake history.
Changes:
- Introduces
Get-SleepWakeHistoryto pair sleep and wake events and report durations, reasons, and wake sources. - Shows how to identify and disable wake permissions for scheduled tasks and devices.
- Documents Modern Standby, battery settings, and hibernation limitations with reported test results.
No concerns identified under the article-specific unsafe-content, AI-content-signal, or self-promotion checks. Final publication remains a maintainer decision.
| File | Description |
|---|---|
| content/articles/2026/11/find-what-wakes-a-windows-pc-with-get-winevent/index.md | Adds the troubleshooting article, PowerShell examples, sample output, and platform caveats. |
Review effort: Balanced
The validate:articles step requires an _index.md in every month folder. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AXY6pfEzpyB9Cjasa4B4S9
Pick the event 42 closest to SleepTime so a later sleep's event in the window isn't matched, and compute Asleep from the DateTimeOffset values so a sleep across a daylight saving change has the right length. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AXY6pfEzpyB9Cjasa4B4S9
|
Looks good! Thanks for the submission. Consider submitting an author bio https://github.com/PowerShellOrg/PowerShellOrgWebsite/blob/main/CONTRIBUTING.md#adding-your-author-profile |


Closes #428
This adds the article pitched in #428. It builds
Get-SleepWakeHistory, which pairs Kernel-Power event 42 with Power-Troubleshooter event 1 to show when a PC slept, why it went to sleep, and what woke it. It then lists the scheduled tasks withWakeToRunset and the devices armed to wake the PC, and shows how to turn off each one.The code was tested in Windows PowerShell 5.1 and PowerShell 7.6 on two Windows 11 PCs (builds 26200 and 26300), a desktop that uses S3 sleep and a Modern Standby laptop. Every output block in the article comes from those runs.