lensapp / lens

Lens - The way the world runs Kubernetes
https://k8slens.dev/
MIT License
22.48k stars 1.46k forks source link

Flatpak extension install: stuck on "Unpacking extension" #7958

Open awoimbee opened 11 months ago

awoimbee commented 11 months ago

Describe the bug

I'm using the dev.k8slens.OpenLens Flatpak. I use for debugging sudo flatpak override dev.k8slens.OpenLens --filesystem=host.

When I try to install an extension (@alebcay/openlens-node-pod-menu), Lens gets stuck on "Unpacking extension ${extension_name}".

To Reproduce

  1. flatpak run dev.k8slens.OpenLens
  2. ctrl+shift+e
  3. install @alebcay/openlens-node-pod-menu
  4. Lens is stuck
$ cd /run/user/1000/app/dev.k8slens.OpenLens/lens-extensions/
$ ls
-rw-r--r-- 1 arthur arthur 4.4K Oct 18 10:44 openlens-node-pod-menu-0.1.2.tgz
drwxr-xr-x 2 arthur arthur   40 Oct 18 10:44 openlens-node-pod-menu-0.1.2.tgz-unpacked
$ ls openlens-node-pod-menu-0.1.2.tgz-unpacked

Note that I can manually unpack the extension, but Lens is still stuck:

$ pigz -dc openlens-node-pod-menu-0.1.2.tgz | tar xf -
$ mv package openlens-node-pod-menu-0.1.2.tgz-unpacked/package

Screenshots

Screenshot from 2023-10-18 10-33-08

Environment

Logs

None, flatpak run returns immediately.

redtux commented 11 months ago

Hi, just in case you haven't stumbled across already: This might be a duplicate of https://github.com/flathub/dev.k8slens.OpenLens/issues/1.

(At least it looks like the same "broader topic", although there was also no solution provided so far.)

awoimbee commented 11 months ago

Hi, just in case you haven't stumbled across already [...]

Thanks a lot ! I had to manually extract the extension inside ~/.var/app/dev.k8slens.OpenLens/config/OpenLens/node_modules/@alebcay/openlens-node-pod-menu/.

I'll close this issue once we find the root cause (does fix requires change to the flatpak or to Lens itself ?).

EDIT: Full procedure for future reference

# Open Lens
# ctrl+shift+e
# Install '@alebcay/openlens-node-pod-menu' -> install is stuck/does-nothing
# COMPLETELY close lens, then:
cd /run/user/1000/app/dev.k8slens.OpenLens/lens-extensions/ 
pigz -dc openlens-node-pod-menu-0.1.2.tgz | tar xf -
mkdir -p /home/arthur/.var/app/dev.k8slens.OpenLens/config/OpenLens/node_modules/@alebcay/
mv package/ /home/arthur/.var/app/dev.k8slens.OpenLens/config/OpenLens/node_modules/@alebcay/openlens-node-pod-menu/
# Open Lens again
redtux commented 11 months ago

does fix requires change to the flatpak or to Lens itself?

Hi @awoimbee, I am not experiencing this issue within the deb package of OpenLens, so I guess it might be an issue with the flatpak package (but I'm not sure).