mijorus/gearlever

[Regression] My managed AppImages are gone and I can't re-add them

Closed this issue · 11 comments

I've just updated Gear Lever to the latest version (1.6.1) and noticed my managed AppImages were gone (from inside the app, not from the menu), also noticing I could'nt re-add them anymore. After some digging and even deleting the app data in order to clear any weird state, it seems to me that the strings binary is missing from the sandbox. Here's the traceback when I try to add an AppImage:

  File "/app/share/gearlever/gearlever/GearleverWindow.py", line 214, in on_drop_event
    return self.on_selected_local_file(list(value))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/share/gearlever/gearlever/GearleverWindow.py", line 140, in on_selected_local_file
    if len(files) == 1 and self.app_details.set_from_local_file(files[0]):
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/share/gearlever/gearlever/AppDetails.py", line 114, in set_from_local_file
    list_element = appimage_provider.create_list_element_from_file(file)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/share/gearlever/gearlever/providers/AppImageProvider.py", line 499, in create_list_element_from_file
    generation=self.get_appimage_generation(file)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/share/gearlever/gearlever/providers/AppImageProvider.py", line 477, in get_appimage_generation
    check = terminal.sandbox_sh(['strings', '-d', '-n', str(len(detect_v3)), file.get_path()])
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/share/gearlever/gearlever/lib/terminal.py", line 33, in sandbox_sh
    output = subprocess.run(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/subprocess.py", line 548, in run
    with Popen(*popenargs, **kwargs) as process:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/subprocess.py", line 1026, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.11/subprocess.py", line 1955, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'strings'

Just reproduced this on my laptop, immediately after the update it doesn't print any traceback, but the logs contain the same No such file or directory: 'strings' error

nerun commented

Exactly the same error here.

Me too! Logs:

ERROR:root:gtk-dialog-error-quark: Dismissed by user (2)
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/appimage-downloads/Bitwarden-2024.1.0-x86_64.AppImage
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/appimage-downloads/HTTPie-2024.1.2.AppImage
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/appimage-downloads/jan-linux-x86_64-0.4.6.AppImage
INFO:root:Reloading metadata for /home/olaolu/AppImages/jan.appimage
INFO:root:Removing /home/olaolu/AppImages/jan.appimage
INFO:root:Trashing /home/olaolu/AppImages/jan.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_jan_0e704c.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_p5r6d2da55/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/Bitwarden-2024.1.0-x86_64.AppImage
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/HTTPie-2024.1.2.AppImage
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/jan-linux-x86_64-0.4.6.AppImage
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/ente-1.7.0-x86_64.AppImage
INFO:root:Reloading metadata for /home/olaolu/appimage-apps/ente.appimage
INFO:root:Removing /home/olaolu/appimage-apps/ente.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/ente.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_ente_95f7c7.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_88r69243x4/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/ente-auth-v2.0.54-x86_64.AppImage
INFO:root:Reloading metadata for /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_auth_92726a.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_qd7yy6aqz9/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Saving config to /home/olaolu/.var/app/it.mijorus.gearlever/config/apps.json
INFO:root:Reloading metadata for /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_auth_92726a.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_16yq359124/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Reloading metadata for /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_auth_92726a.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_d1x9cxp39b/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Removing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_auth_92726a.desktop
INFO:root:Removing /home/olaolu/appimage-apps/ente.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/ente.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_ente_95f7c7.desktop
INFO:root:Exctracting with p7zip
INFO:root:Installing appimage: /home/olaolu/Downloads/appimages/ente-auth-v3.0.4-x86_64.AppImage
INFO:root:Reloading metadata for /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Trashing /home/olaolu/appimage-apps/auth.appimage
INFO:root:Removing /home/olaolu/.local/share/applications/gearlever_auth_5e406e.desktop
INFO:root:Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_4ay9z6azc1/tmp.appimage
INFO:root:Exctracting with p7zip
INFO:root:Exctracting with p7zip
INFO [AppImageProvider.py:194] Removing /home/olaolu/appimage-apps/auth.appimage
INFO [AppImageProvider.py:199] Trashing /home/olaolu/appimage-apps/auth.appimage
INFO [AppImageProvider.py:207] Removing /home/olaolu/.local/share/applications/gearlever_auth_5e406e.desktop
INFO [AppImageProvider.py:583] Exctracting with p7zip to /tmp/it.mijorus.gearlever/appimages/gearlever_b29a9b87p8/squashfs-root
INFO [AppImageProvider.py:259] Installing appimage: /home/olaolu/Downloads/appimages/ente-auth-v3.0.8-x86_64.AppImage
INFO [AppImageProvider.py:450] Reloading metadata for /home/olaolu/appimage-apps/auth.appimage
INFO [AppImageProvider.py:194] Removing /home/olaolu/appimage-apps/auth.appimage
INFO [AppImageProvider.py:199] Trashing /home/olaolu/appimage-apps/auth.appimage
INFO [AppImageProvider.py:207] Removing /home/olaolu/.local/share/applications/gearlever_auth_890769.desktop
INFO [AppImageProvider.py:259] Installing appimage: /tmp/it.mijorus.gearlever/appimages/gearlever_64aadp7q57/tmp.appimage
INFO [AppImageProvider.py:583] Exctracting with p7zip to /tmp/it.mijorus.gearlever/appimages/gearlever_4a2y8yzqyx/squashfs-root
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
ERROR [GearleverWindow.py:246] gtk-dialog-error-quark: Dismissed by user (2)
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
ERROR [GearleverWindow.py:246] gtk-dialog-error-quark: Dismissed by user (2)
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
DEBUG [utils.py:37] 

---- Application startup | version 1.6.1
DEBUG [main.py:55] ::: Settings
DEBUG [main.py:57] exec-as-name-for-terminal-apps: true
DEBUG [main.py:57] last-run-version: '1.0.0'
DEBUG [main.py:57] first-run-v2: true
DEBUG [main.py:57] first-run: false
DEBUG [main.py:57] manage-files-outside-default-folder: true
DEBUG [main.py:57] debug-logs: true
DEBUG [main.py:57] is-maximized: false
DEBUG [main.py:57] appimages-default-folder: '/home/olaolu/appimage-apps'
DEBUG [main.py:57] move-appimage-on-integration: false
DEBUG [main.py:57] simple-file-name-for-apps: true
DEBUG [main.py:59] ::: End settings
DEBUG [AppImageProvider.py:137] /home/olaolu/.local/share/applications/Mailspring.desktop skipped because  does not exists on the filesystem
DEBUG [AppImageProvider.py:137] /home/olaolu/.local/share/applications/kitty.desktop skipped because kitty does not exists on the filesystem
DEBUG [utils.py:37] Running ['strings', '-d', '-n', '29', '/home/olaolu/appimage-apps/bitwarden.appimage']
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
DEBUG [utils.py:37] Running ['strings', '-d', '-n', '29', '/home/olaolu/appimage-apps/httpie.appimage']
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
DEBUG [utils.py:37] Running ['strings', '-d', '-n', '29', '/home/olaolu/appimage-apps/jan.appimage']
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
DEBUG [utils.py:37] Running ['strings', '-d', '-n', '29', '/home/olaolu/appimage-apps/auth.appimage']
WARNING [AppImageProvider.py:140] [Errno 2] No such file or directory: 'strings'
DEBUG [AppImageProvider.py:137] /home/olaolu/.local/share/applications/org.gnome.Shell.Extensions.GSConnect.desktop skipped because  does not exists on the filesystem
DEBUG [AppImageProvider.py:137] /home/olaolu/.local/share/applications/org.gnome.Shell.Extensions.GSConnect.Preferences.desktop skipped because  does not exists on the filesystem

I'm sorry guys, I'll release an update asap

You might already be aware of this @mijorus, but doing some digging, it looks like this line might be the culprit. Though, I don't know why a binary is being treated like a file path, maybe an issue with python subprocesses, idk

It was working just fine on my system btw

It was working just fine on my system btw

As a flatpak?

Yeah

nerun commented

For me no, not working.

nerun commented

Fixed with 1.6.2, working now.

Thanks for contributing with this bug report.

If you want to support my work, please consider a small donation.

https://ko-fi.com/mijorus