Bug 479480 - Optionally disable standby when download or upload is in progress (Firefox workaround)
Summary: Optionally disable standby when download or upload is in progress (Firefox wo...
Status: RESOLVED FIXED
Alias: None
Product: plasma-browser-integration
Classification: Plasma
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Fedora RPMs Linux
: NOR wishlist
Target Milestone: ---
Assignee: Kai Uwe Broulik
URL:
Keywords: usability
Depends on:
Blocks:
 
Reported: 2024-01-06 19:59 UTC by postix
Modified: 2025-08-09 10:21 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.5.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description postix 2024-01-06 19:59:39 UTC
SUMMARY

I have set the system to auto standby after X minutes. This is however undesired if an active download or upload is in progress as the browser will cancel the operation, meaning one has to start downloading or uploading again.

A workaround would be to go the battery applet and set "Manually disable suspend or display locking", however display locking still makes sense in this use case.

The other workaround is to go to the system settings and manually disable and later re-enable suspend. This is in practice of course not practical.

It'd be great to have an option in the addon to allow to automatically do the steps mentioned above + some hint which informs about it. 


SOFTWARE/OS VERSIONS
Operating System: Fedora Linux 39
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.111.0
Qt Version: 5.15.11
Kernel Version: 6.6.8-200.fc39.x86_64 (64-bit)
Graphics Platform: Wayland
Browser: Firefox 121 Wayland
Plasma Integration: 1.8.1
Comment 1 Kai Uwe Broulik 2024-01-06 20:01:13 UTC
Chrome does that on its own, I suppose Firefox should do the same.
Comment 2 postix 2024-01-06 20:07:29 UTC
(In reply to Kai Uwe Broulik from comment #1)
> Chrome does that on its own, I suppose Firefox should do the same.

I believe I had experienced the same issue on openSUSE TW as well. Unfortunately I cannot find any information about the default Firefox behavior on the web, but will do further research later.
Comment 3 postix 2024-01-06 20:42:47 UTC
Looks like this is an Firefox bug: 

[1] Firefox doesn't prevent gnome-shell from going into suspend mode while active downloads remain
https://bugzilla.mozilla.org/show_bug.cgi?id=1449136 (6 years old)

[2] Firefox doesn't prevent Windows from going into suspend mode while active downloads remain
https://bugzilla.mozilla.org/show_bug.cgi?id=356762 (17 years old)

Could plasma integration maybe add a workaround? It doesn't look like it's going to be fixed any time soon. :-(
Comment 4 postix 2024-01-06 20:48:50 UTC
Could also be bug 

[3] Downloads get suspended when screen is locked  https://bugzilla.mozilla.org/show_bug.cgi?id=1719213 (3 years old)
Comment 5 Kai Uwe Broulik 2024-01-06 20:50:24 UTC
Having p-b-i post a power management inhibition on behalf of Firefox should be trivial (we track all of its running downloads already anyway), but for that lock screen but we cannot do much I guess.
Comment 6 postix 2024-01-11 17:43:31 UTC
> Having p-b-i post a power management inhibition on behalf of Firefox should be trivial
That should be sufficient, thank you in advance! :)
Comment 7 Bug Janitor Service 2025-07-25 18:03:43 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-browser-integration/-/merge_requests/158
Comment 8 Kai Uwe Broulik 2025-08-02 16:46:22 UTC
Git commit b738862685df6b69adc848733d559e79c30e4f8f by Kai Uwe Broulik.
Committed on 02/08/2025 at 16:14.
Pushed by broulik into branch 'master'.

Add option to inhibit suspend while downloading

There's an ancient Firefox bug report about this that doesn't appear
to be going anywhere, so let's just do it ourselves.

It's on by default and provided only to Firefox since Chrome
inhibits by itself.

M  +4    -0    extension/_locales/en/messages.json
M  +5    -3    extension/constants.js
M  +6    -0    extension/options.html
M  +24   -3    host/downloadplugin.cpp
M  +7    -1    host/downloadplugin.h

https://invent.kde.org/plasma/plasma-browser-integration/-/commit/b738862685df6b69adc848733d559e79c30e4f8f