New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ability to prevent system from entering sleep/hibernation while downloading #751
Comments
@nmaier Are you interested in this? |
Really useful and i think this is an important feature for the future. |
If using the older
|
ES_SYSTEM_REQUIRED should be quite enough to prevent a computer from sleeping. |
In xubuntu i have a similar issue the pc suspend. aria2c version: aria2 versión 1.36.0 This program is free software; you can redistribute it and/or modify This program is distributed in the hope that it will be useful, ** Configuration ** |
My Windows systems (desktops and battery-powered devices) are set to automatically sleep/hibernate on user inactivity after a specified time period. All the well-coded download managers, media players, disc burners, presentation software etc. that I use nowadays are able to deny the system from entering sleep/hibernation while they are busy executing user-initiated tasks, and so I don't have to tinker with my power settings unnecessarily. Windows has long provided power management APIs to enable such use cases.
Currently however I have to either remember to manually modify my active power plan both before and after using aria2 (which is naturally cumbersome and often leads to an undesirable system state when I forget either of the two), or I need to use a batch file every time that automates the before/after power plan edits using powercfg or similar (which is painful as well).
It would thus be highly desirable if aria2 itself could invoke the standard OS power management APIs, exposed to end users via something like a --keep-system-awake-till-done option. The program's documentation doesn't seem to mention which versions of Windows it works on, but if XP and Vista are no longer supported then the enhanced PowerCreateRequest/PowerSetRequest/PowerClearRequest APIs can be used, otherwise the still supported SetThreadExecutionState API can be relied upon.
Further detailed information about the APIs is available from the usual sources, including MSDN of course and specifically the Power Availability Requests document available here (the New Functions for Availability Requests section therein should help).
Thanks for reading, and I hope this feature will be implemented in a future version of this wonderful utility.
The text was updated successfully, but these errors were encountered: