Preferences app takes some seconds to respond after launch

REPRODUCIBILITY (% or how often): 100%
BUILD ID = OS VERSION (Settings > About product): 4.3.0, 4.4.0
HARDWARE (XA2, X10, X10 II, …): XA2
UI LANGUAGE:
REGRESSION: (compared to previous public release: Yes, No, ?): Yes

DESCRIPTION:

Starting from 4.3.0, the menu of the Prefs app does not respond to any input for some seconds. This persists in 4.4.0.

STEPS TO REPRODUCE:

  1. Launch the Preferences app.
  2. Try to scroll the menu or to select a menu item

EXPECTED RESULT:

The menu scrolls and menu items respond to selection immediately.

ACTUAL RESULT:

No response from the app UI for 3-4 seconds, after which the apps works normally.

1 Like

I have the same error on my X10 II. Here are some logs if a start jolla-settings from terminal:

** (process:26618): WARNING **: 21:38:41.758: Cannot create directory: /home/defaultuser/.local/share/system/privileged/Accounts/libaccounts-glib
** (process:26618): WARNING **: 21:38:41.761: Error opening accounts DB: unable to open database file
[W] unknown:0 - Manager could not be created. DB is locked
** (process:26618): CRITICAL **: 21:38:41.762: ag_manager_list_services: assertion 'AG_IS_MANAGER (manager)' failed
** (process:26618): CRITICAL **: 21:38:41.762: ag_manager_set_db_timeout: assertion 'AG_IS_MANAGER (manager)' failed
** (process:26618): CRITICAL **: 21:38:41.763: ag_manager_list: assertion 'AG_IS_MANAGER (manager)' failed

On my old Jolla 1 running SailfishOS 3.4, I don’t see these errors.

1 Like

The Settings app needs special privileges to access the accounts data. You’ll need to prefix the command with devel-su -p to gain the privileges needed in order to avoid those errors, like this:

devel-su -p jolla-settings

(this is only needed when running from the terminal).

It would certainly be good to check the log output with the command above, I think, to see if there’s anything that relates to the delays.

2 Likes

Tried again and you’re right. I could catch the right “error”:

[W] unknown:0 - libpng warning: iCCP: known incorrect sRGB profile

I can scroll only once this line appear.

2 Likes

Thanks for identifying this @pherjung. Unfortunately this warning seems to be output from deep in the depths of qtbase, making it hard to determine what’s causing it.

Assuming this is to do with the launcher icons (as is suggested by the other thread on this topic), it might be possible to collect a little more data though.

However, this requires editing a system file, and any changes could completely break the UI of your device, so that it requires reflashing. So, please proceed with caution and only if you’re willing to lose all data on your device.

Assuming that’s okay…

…edit the file /usr/lib/qt5/qml/Sailfish/Lipstick/LauncherIcon.qml (note this file will be in /usr/lib64 on 64-bit devices).

Then add the following on line 19 to log the icons being shown:

        console.log("Loading file: " + icon)

so that it looks like this:

    source: {
        console.log("Loading file: " + icon)
        if (icon.indexOf(':/') !== -1 || icon.indexOf("data:image/png;base64") === 0) {
            return icon
...etc...

After making this change you should see a list of images output to the log. If one of them is causing a delay, this may help determine which one.

Could it be some leftover from the preferences menu item of AlienDalvik Control?

Nope, because I never installed it.

On line 19, nothing changed. So I added under each condition. And here we go:

1 Like

Great work, thank you! Given the placement of the libpng warning, that suggests either Working Hours Tracker or the Chum GUI may be contributing to the issue.

I’ll give them a go and see if I can reproduce it.

Uninstalling Working Hours didn’t change anything.

Thanks for checking. Do you still get the libpng warning after uninstalling it?

Warning has disappeared, but the latency is still present.

Okay, maybe the warning was a red-herring then. When you view the output now, can you observer at which point the delay occurs?

I’ll try it tonight with some console.time. Which file should I modify to output some log once I click on an item? For instance Ambiances.

I’ve noticed that a lot of apps take longer to open and be ‘ready for action’ on my XA2 since I upgraded to 4 4.

To date I just put this down, purely by uninformed guess work, to the extra processing load of Sailjail when an app starts up.

Things are therefore not as snappy as they used to be, but its no real inconvenience.

I started a thread here on a similar topic. Speed at which Sailfish apps launch

1 Like

In the case of the Settings app things are slightly different, because it runs with Sailjail disabled.

Just recently i noticed, the delay is still somewhat present with 4.4.0.68. It is not as bad as it was with .58 (now only maybe half a second). I think the settings app responded without a delay after a fresh install. Is anyone else experiencing this?

Given that nothing that should be relevant for the issue changed between .58 and .64, i think your mind is playing tricks on you. Maybe you have just installed more apps etc (the other tabs now load together with the main view since a few releases).

No, my mind is not playing tricks. The delay IS there.