microsoft / microsoft/PowerToys
Allow for simultaneous usage of CLI arguments "--use-parent-id" and "--expire-at"
- Dominant language
- C
- Stars
- 139k
- Forks
- 8.6k
- PR merge metrics
- PR metrics pending
Description
This was originally a bug report but after reading it you should get the gist.
### Microsoft PowerToys version
0.98.0
### Installation method
WinGet
### Area(s) with issue?
Awake
### Steps to reproduce
I have attempted 2 ways:
Powershell (for testing I know closing powershell closes Powertoys.Awake this way):
As the Powertoys.Awake.exe cmdlet is not functional at all. I had to use `Start-Process 'C:\Program Files\PowerToys\PowerToys.Awake.exe' -ArgumentList "--expire-at=17:00:00", "--use-parent-pid"`
Task Scheduler:
Open executable: `C:\Program Files\PowerToys\PowerToys.Awake.exe`
Arguments: `--expire-at=17:00:00 --use-parent-pid`
I have in both cases swapped arguments. I also checked if it worked without `--use-parent-pid`
### ✔️ Expected Behavior
When using `--use-parent-pid`:
Powertoys Awake runs in my taskbar and keeps my PC awake until the designated time.
When not using `--use-parent-pid`:
Powertoys just runs in my taskbar as an icon instead of opening a CLI that shows me some output when clicking the taskbar icon saying it failed to render it. I need this PC both awake and idiot (sorry users of my PC) proof.
### ❌ Actual Behavior
When using `--use-parent-pid` it ignores `--expire-at=17:00:00` and keeps awake indefinitely.
When not using `--use-parent-pid` it technically works fine, except that there's an unclosable CLI (I know it's minimizable but the computer is used by people who need to not be able to touch it because they will close it)
### Upload Bug Report ZIP-file
_No response_
### Additional Information
WIndows 11 Pro. It's up to date as of March 19 2026
It also does not show the right-click menu on the taskbar icon in all scenario's
### Other Software
_No response_
Contributor guide
Research direction
Start at the Awake executable's command-line argument handling for --use-parent-pid and --expire-at, using the reproduction commands in this issue. Verify how the two options interact, then add or update coverage so both options work together and the process stops at the requested time.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- powershell
- Domain
- cli, desktop, operating-systems
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100