Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't update my extension bracketstoix #328

Closed
a-bentofreire opened this issue Aug 22, 2024 · 19 comments
Closed

Can't update my extension bracketstoix #328

a-bentofreire opened this issue Aug 22, 2024 · 19 comments

Comments

@a-bentofreire
Copy link

a-bentofreire commented Aug 22, 2024

I would like to update my extension: BracketsToIX to a newer version, but I face 2 issues:

  1. The registry https://registry.brackets.io/ doesn't let sign in via my github account.
    It points to https://localhost:3000/auth/github/callback?code=(number) - My comment bellow points to an alternative way.
  2. I have downloaded app via https://phcode.io/#/home, with wget -qO- https://updates.phcode.io/linux/installer.sh | bash`
    When I execute on Linux Mint 22, the phoenix-code 3.8.8, it just shows 'Ops! Something went wrong. Try restaring the app' right after the execution without allowing me to do anything.
@a-bentofreire
Copy link
Author

Regarding the update the extension on the registry, I read another previous posted issue, which points to:
https://github.com/phcode-dev/phoenix/wiki/How-To-Write-Extensions-And-Themes
I will try this new approach, but I would still like to be able to execute the application offline, at the moment the only way I see that I can execute phcode is via online phcode.dev on chrome.

@a-bentofreire
Copy link
Author

a-bentofreire commented Aug 22, 2024

Although, I still can't execute it locally, I tried online and it works. It's enough for me.

@abose
Copy link
Member

abose commented Aug 22, 2024

hi @a-bentofreire Phoenix code has deprecated support for legacy node as it relied on an ancient node version. That may be the reason why the extension failed to load in desktop builds.

There is a brand new and eazier node framework now available based on node20. Please see https://github.com/phcode-dev/extension-node-template on how to use this.

Do drop an issue or discussion for any help in https://github.com/phcode-dev/phoenix as that is the main tracking repo now for brackets development.

@a-bentofreire
Copy link
Author

hi @a-bentofreire Phoenix code has deprecated support for legacy node as it relied on an ancient node version. That may be the reason why the extension failed to load in desktop builds.

There is a brand new and eazier node framework now available based on node20. Please see https://github.com/phcode-dev/extension-node-template on how to use this.

Do drop an issue or discussion for any help in https://github.com/phcode-dev/phoenix as that is the main tracking repo now for brackets development.

Thank you for reply, but the desktop version reported this issue as soon as I executed after I download the app without any extension loaded, so it's not related to my extension or any other extension.

@abose
Copy link
Member

abose commented Aug 22, 2024

hi @a-bentofreire Phoenix code has deprecated support for legacy node as it relied on an ancient node version. That may be the reason why the extension failed to load in desktop builds.

There is a brand new and eazier node framework now available based on node20. Please see https://github.com/phcode-dev/extension-node-template on how to use this.

Do drop an issue or discussion for any help in https://github.com/phcode-dev/phoenix as that is the main tracking repo now for brackets development.

Thank you for reply, but the desktop version reported this issue as soon as I executed after I download the app without any extension loaded, so it's not related to my extension or any other extension.

Ah! This is on linux i see. @charlypa is linux mint 22 supported?

@charlypa
Copy link
Member

@a-bentofreire @abose
phoenix code work for me in mint 22
image

@a-bentofreire would you tell us exactly what is missing

@a-bentofreire
Copy link
Author

  1. I have deleted all traces of the application installed yesterday, and redo the whole process
  2. I download and installed the app: wget -qO- https://updates.phcode.io/linux/installer.sh | bash
  3. I execute the app: /home/abf/.phoenix-code/phoenix-code
  4. As soon as it enters, it pops a dialog box with Ops...
  5. On the first time it displays: No boot restore config file found /home/abf/.local/share/io.phcode/boot_config.json, but after executing again, no message on console but always the same popup dialog Ops...

System:
Kernel: 6.8.0-41-generic arch: x86_64 bits: 64 compiler: gcc v: 13.2.0
Desktop: Cinnamon v: 6.2.9 Distro: Linux Mint 22 Wilma
base: Ubuntu 24.04 noble
Machine:
Type: Laptop System: LENOVO product: 81YK v: IdeaPad 5 15IIL05
serial:
Mobo: LENOVO model: LNVNB161216 v: SDK0J40700 WIN
serial: UEFI-[Legacy]: LENOVO v: DPCN43WW
date: 06/11/2020
Graphics:
Device-1: Intel Iris Plus Graphics G1 vendor: Lenovo driver: i915 v: kernel
arch: Gen-11 bus-ID: 00:02.0
Device-2: IMC Networks Integrated Camera driver: uvcvideo type: USB
bus-ID: 3-5:3
Display: x11 server: X.Org v: 21.1.11 with: Xwayland v: 23.2.6 driver: X:
loaded: modesetting unloaded: fbdev,vesa dri: iris gpu: i915
resolution: 1920x1080~60Hz
API: EGL v: 1.5 drivers: iris,swrast platforms:
active: x11,surfaceless,device inactive: gbm,wayland
API: OpenGL v: 4.6 compat-v: 4.5 vendor: intel mesa v: 24.0.9-0ubuntu0.1
glx-v: 1.4 direct-render: yes renderer: Mesa Intel UHD Graphics (ICL GT1)

Screenshot from 2024-08-22 11-35-18
Screenshot from 2024-08-22 11-35-43

I'm attaching screenshots

@a-bentofreire
Copy link
Author

I see from your installation something about the installation of webkit2gtk. which version do you have installed?
I had already pre-installed these 2:

gir1.2-webkit2-4.1/noble-updates,now 2.44.2-0ubuntu0.24.04.2 amd64 [installed]
libwebkit2gtk-4.1-0/noble-updates,now 2.44.2-0ubuntu0.24.04.2 amd64 [installed]

@a-bentofreire
Copy link
Author

Another issue unrelated to the desktop version: when I execute the online version, I see two version available of my extension, the old one, and the new version that I updated yesterday. Can you delete the old version From the extension registry. I used the same repo as before, and followed the guidelines described on the template.
Screenshot from 2024-08-22 11-47-32

@a-bentofreire a-bentofreire reopened this Aug 22, 2024
@charlypa
Copy link
Member

charlypa commented Aug 22, 2024

@a-bentofreire
Please edit file /home/abf/.phoenix-code/phoenix-code and replace with below contents.

#!/bin/bash
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
export LD_LIBRARY_PATH=$SCRIPT_DIR/gtk:$LD_LIBRARY_PATH
ldd $SCRIPT_DIR/phoenix-code.app "$@" | grep webk

Then execute file /home/abf/.phoenix-code/phoenix-codeand can you report the errors in console to help us debug the issue.

@a-bentofreire
Copy link
Author

@a-bentofreire Please edit file /home/abf/.phoenix-code/phoenix-code and replace with below contents.

#!/bin/bash
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
export LD_LIBRARY_PATH=$SCRIPT_DIR/gtk:$LD_LIBRARY_PATH
ldd $SCRIPT_DIR/phoenix-code.app "$@" | grep webk

Then execute file /home/abf/.phoenix-code/phoenix-codeand can you report the errors in console to help us debug the issue.

This is the output

/home/abf/.phoenix-code/phoenix-code
libwebkit2gtk-4.0.so.37 => /home/abf/.phoenix-code/gtk/libwebkit2gtk-4.0.so.37 (0x00007c990aa00000)

@charlypa
Copy link
Member

@a-bentofreire
Looks like the proper webkit is being loaded. To debug it further
Please edit file /home/abf/.phoenix-code/phoenix-code and replace with below contents.

#!/bin/bash
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
export LD_LIBRARY_PATH=$SCRIPT_DIR/gtk:$LD_LIBRARY_PATH
ldd $SCRIPT_DIR/phoenix-code.app "$@" 

Then execute file /home/abf/.phoenix-code/phoenix-code and can you report the errors in console to help us debug the issue.

@a-bentofreire
Copy link
Author

No worries, I'm attaching the library list (the output)
libraries.txt

@abose
Copy link
Member

abose commented Aug 23, 2024

@a-bentofreire i will remove the duplicate extension in a day or two as i need to write a remove extension workflow which we delayed implementing till someone asks for it.

We try hard to make phcode work in all linux distros out there, but some distros have some quirks to iron out. If you can help a bit, i can share a custom debug build to identity the issue. Just need to execute it and share the results.

@a-bentofreire
Copy link
Author

@a-bentofreire i will remove the duplicate extension in a day or two as i need to write a remove extension workflow which we delayed implementing till someone asks for it.

We try hard to make phcode work in all linux distros out there, but some distros have some quirks to iron out. If you can help a bit, i can share a custom debug build to identity the issue. Just need to execute it and share the results.

Thank you for removing the duplicate.
I will have look at phcode as soon as I have a bit of time

@abose
Copy link
Member

abose commented Aug 26, 2024

@a-bentofreire I created a custom debug build to identify the issue. Can you download it from https://github.com/abose/wer/releases/download/fedoraDebug/portable-debug-build-3.9.1.zip , extract and run ./phoenix-code-experimental-build

@a-bentofreire
Copy link
Author

@abose

  1. If I extract the complete zip to ~/Downloads and execute from ~/Downloads/portable-debug-build/phoenix-code-experimental-build, I have the error message: ./phoenix-code-experimental-build: error while loading shared libraries: libwebkit2gtk-4.0.so.37: cannot open shared object file: No such file or directory

  2. If I place it on /home/abf/.phoenix-code and tweak the code of phoenix-code to :

#!/bin/bash
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
export LD_LIBRARY_PATH=$SCRIPT_DIR/gtk:$LD_LIBRARY_PATH
echo $LD_LIBRARY_PATH
exec $SCRIPT_DIR/phoenix-code-experimental-build "$@"

It executes without issues.
It displays the following messages on console, but no error dialog on the app:

/home/abf/.phoenix-code/gtk:
Appdata path is /home/abf/.local/share/io.phcode.dev
No boot restore config file found /home/abf/.local/share/io.phcode.dev/boot_config.json
Asset `assets/notifications/dev/en-US/banner.json` not found; fallback to assets/notifications/dev/en-US/banner.json.html

@abose
Copy link
Member

abose commented Aug 26, 2024

@a-bentofreire The break was due to some linux distros not returning the user documents folder correctly. The fix will be available in the next release. In the meantime, you can use the build i shared till the release is out. Thanks again for helping with the fix.

@a-bentofreire
Copy link
Author

perfect!
I will close this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants