alebcay / openlens-node-pod-menu

Node and pod menus for OpenLens
https://www.npmjs.com/package/@alebcay/openlens-node-pod-menu
MIT License
801 stars 43 forks source link

When clicking on Pod Shell the terminal crashes #159

Closed shalomm-gloat closed 7 months ago

shalomm-gloat commented 7 months ago

When trying to open up the Pod Shell button the terminal is opens up however, crashes.

Logs:

image

Screen recording: Recording 2024-01-08 at 17 03 07

I'm using: MacBook Pro 2021 16׳ Apple M1 chip Sonoma 14.2.1

OpenLens settings: OpenLens: 6.5.2+286 Extension API: 6.5.2 Electron: 22.3.3 Chrome: 108.0.5359.215 Node: 16.17.1 © 2023 OpenLens Authors

@k8slens/application: ^6.5.0 @k8slens/application-for-electron-main: ^6.5.0 @k8slens/button: ^1.0.0 @k8slens/cluster-settings: ^6.5.0 @k8slens/core: ^6.5.2 @k8slens/ensure-binaries: ^6.5.0 @k8slens/error-boundary: ^1.0.0 @k8slens/event-emitter: ^1.0.0 @k8slens/feature-core: ^6.5.0 @k8slens/keyboard-shortcuts: ^1.0.0 @k8slens/kube-object: ^1.0.0 @k8slens/kubectl-versions: ^1.0.0 @k8slens/legacy-extension-example: ^1.0.2 @k8slens/legacy-extensions: ^1.0.0 @k8slens/legacy-global-di: ^1.0.0 @k8slens/list-layout: ^1.0.0 @k8slens/logger: ^1.0.0 @k8slens/messaging: ^1.0.0 @k8slens/messaging-for-main: ^1.0.0 @k8slens/messaging-for-renderer: ^1.0.0 @k8slens/metrics: ^6.5.0 @k8slens/node-fetch: ^6.5.0 @k8slens/react-application: ^1.0.0 @k8slens/resizing-anchor: ^1.0.0 @k8slens/resource-templates: ^1.0.0 @k8slens/routing: ^1.0.0 @k8slens/run-many: ^1.0.0 @k8slens/startable-stoppable: ^1.0.0 @k8slens/tooltip: ^1.0.0 @k8slens/utilities: ^1.0.0 @k8slens/legacy-extension-example: 1.0.2

alebcay commented 7 months ago

Hi, thanks for the bug report. Can you please try updating to the latest available version of OpenLens from the releases page https://github.com/MuhammedKalkan/OpenLens/releases (v6.5.2-366 at time of writing) and see if this helps resolve the issue? I see you are currently on v6.5.2-286.

The UI code for the pod logs tab is in the OpenLens application itself; this extension merely exposes it via menu buttons.

otterobert commented 7 months ago

using latest version and same thing happens to me:

OpenLens: 6.5.2-366 Extension API: 6.5.2 Electron: 22.3.3 Chrome: 108.0.5359.215 Node: 16.17.1 © 2023 OpenLens Authors

alebcay commented 7 months ago

Thanks. Can someone who is running into the issue please try running the application from their terminal/command prompt and also provide the logs that are emitted to stdout (these are different than the developer console logs).

On macOS, this can be done on the terminal by running /Applications/OpenLens.app/Contents/MacOS/OpenLens.

otterobert commented 7 months ago

error:   ┏ [KUBECTL]: Failed to get a lock for 1.26.6 Lock file is already being held +2s
error:   ┃ [1] Error: Lock file is already being held
error:   ┃ [2]     at /Applications/OpenLens.app/Contents/Resources/app.asar/node_modules/proper-lockfile/lib/lockfile.js:68:47
error:   ┃ [3]     at callback (/Applications/OpenLens.app/Contents/Resources/app.asar/node_modules/graceful-fs/polyfills.js:306:20)
error:   ┃ [4]     at FSReqCallback.oncomplete (node:fs:207:5)
error:   ┗ [5] { code: 'ELOCKED', file: '/Users/.../Library/Application Support/OpenLens/binaries/kubectl/1.26.6' }
info:    ┏ [UNIX-SHELL-ENV]: running against /bin/zsh +1ms
info:    ┃ [1] {
info:    ┃ [2]   command: ` '/Applications/OpenLens.app/Contents/MacOS/OpenLens' -p '"<HASH>" + JSON.stringify(process.env) + "<HASH>"'`,
info:    ┃ [3]   shellArgs: [ '-l', '-i' ]
info:    ┗ [4] }
info:    ▪ [SHELL-SESSION]: PTY for <SESSION-ID>:<PID> is started with PID=<SOME-PID> +13ms
info:    ▪ [SHELL-SESSION]: shell has exited for <SESSION-ID>:<PID> closed with exitcode=0 +125ms
alebcay commented 7 months ago

Can you try completing quitting OpenLens, deleting the folder /Users/.../Library/Application Support/OpenLens/binaries (adding in your username as appropriate), and then trying again?

otterobert commented 7 months ago

worked 👍

shalomm-gloat commented 7 months ago

@alebcay Thank you so much it's working now :) Closing this.