Bug 424558 - Autostart fires to early
Summary: Autostart fires to early
Status: RESOLVED NOT A BUG
Alias: None
Product: systemsettings
Classification: Applications
Component: kcm_autostart (other bugs)
Version First Reported In: unspecified
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: Laurent Montel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-23 05:48 UTC by Bernd Nachtigall
Modified: 2020-07-27 04:54 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernd Nachtigall 2020-07-23 05:48:14 UTC
When insert a script into autostart (e.g. to stop akonadi ;-) it is started before akonadi runs. So the stop order dit not success. When insert a 'sleep 5' into the script it will success.

So the idea is, to delay the start of the check if there are autostart scripts that has to run a few seconds.
Comment 1 Nicolas Fella 2020-07-23 08:29:29 UTC
What if I want to run my script before Akonadi?

I don't quite understand what you are suggesting in detail, but it sounds somewhat brittle and unpredictable.


Technically speaking what you'd want is to specify dependencies between autostarted things (e.g. skript X runs after Akonadi) instead of randomly delaying things. This is something XDG autostart (https://specifications.freedesktop.org/autostart-spec/autostart-spec-latest.html) does not model. systemd for example has such a mechanism, but I'm not sure it's worth copying that level of complexity here
Comment 2 Bernd Nachtigall 2020-07-23 08:41:12 UTC
Am 23.07.20 um 10:29 schrieb Nicolas Fella:
(...)
> --- Comment #1 from Nicolas Fella <nicolas.fella@gmx.de> --- What if
>  I want to run my script before Akonadi?
>
> I don't quite understand what you are suggesting in detail, but it
> sounds somewhat brittle and unpredictable.

I think that programs/scripts that should run after a GUI is started,
like a graphical configured 'Autostart', should run after the GUI is
started completly. I expect this behavior.

If I want to start a program/script before the GUI is completly started
and ready to work i have to found an other way.
Comment 3 David Edmundson 2020-07-23 08:59:21 UTC
I don't see a reason to change anything here.
Comment 4 Bernd Nachtigall 2020-07-27 04:54:15 UTC
Am 23.07.20 um 10:59 schrieb David Edmundson:
> https://bugs.kde.org/show_bug.cgi?id=424558
(...)
> --- Comment #3 from David Edmundson <kde@davidedmundson.co.uk> ---
> I don't see a reason to change anything here.
>
OK, but than the autostart mechanism should run properly ...

Today this script:

## #!/bin/bash
## #Stops Akonadi
## sleep 10
## akonadictl stop

in ~bin/ with a softlink in ~/.config/autostart-scripts. Does not stop
Akonadi after login to GUI. When execute this manuell via cli it does
its job.