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

[Bug]: 已通过brew安装node,软件内仍要求安装nodejs #21

Closed
3 tasks done
wakewon opened this issue Mar 21, 2023 · 6 comments
Closed
3 tasks done

[Bug]: 已通过brew安装node,软件内仍要求安装nodejs #21

wakewon opened this issue Mar 21, 2023 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@wakewon
Copy link

wakewon commented Mar 21, 2023

前置阅读 | Pre-reading

PicList的版本 | PicList Version

1.4.208(商店)

系统信息 | System Information

Mac

问题重现 | Bug reproduce

在插件设置中尝试安装插件,提示要求安装nodejs:
image

这里还有一个问题是左边栏和顶部有错位

然而之前已通过homebrew安装过node,在picgo里可以正常安装插件。版本信息:
image

相关日志 | Logs

2023-03-21 12:30:38 [PicList INFO] [PicList Server] is listening at 36677
2023-03-21 12:32:45 [PicList ERROR]
------Error Stack Begin------
Error: spawn npm ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)
-------Error Stack End-------
2023-03-21 12:32:45 [PicList ERROR] NPM is not installed
2023-03-21 12:32:45 [PicList ERROR] 插件安装失败,失败码为-2,错误日志为

2023-03-21 12:33:14 [PicList ERROR]
------Error Stack Begin------
Error: spawn npm ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)
-------Error Stack End-------
2023-03-21 12:33:14 [PicList ERROR] NPM is not installed
2023-03-21 12:33:14 [PicList ERROR] 插件安装失败,失败码为-2,错误日志为

2023-03-21 12:33:17 [PicList INFO] [PicList Server] shutdown
2023-03-21 12:33:22 [PicList INFO] [PicList Server] is listening at 36677
2023-03-21 12:34:12 [PicList ERROR]
------Error Stack Begin------
Error: spawn npm ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)
-------Error Stack End-------

@wakewon wakewon added the bug Something isn't working label Mar 21, 2023
@Kuingsmile
Copy link
Owner

dev模式下运行可以安装插件,mas打包后不行。初步判断是由于Macos的沙盒机制导致的,正在尝试修复

@Kuingsmile
Copy link
Owner

Kuingsmile commented Mar 21, 2023

前置阅读 | Pre-reading

PicList的版本 | PicList Version

1.4.208(商店)

系统信息 | System Information

Mac

问题重现 | Bug reproduce

在插件设置中尝试安装插件,提示要求安装nodejs: image

这里还有一个问题是左边栏和顶部有错位

然而之前已通过homebrew安装过node,在picgo里可以正常安装插件。版本信息: image

相关日志 | Logs

2023-03-21 12:30:38 [PicList INFO] [PicList Server] is listening at 36677 2023-03-21 12:32:45 [PicList ERROR] ------Error Stack Begin------ Error: spawn npm ENOENT at ChildProcess._handle.onexit (node:internal/child_process:283:19) at onErrorNT (node:internal/child_process:478:16) at process.processTicksAndRejections (node:internal/process/task_queues:83:21) -------Error Stack End------- 2023-03-21 12:32:45 [PicList ERROR] NPM is not installed 2023-03-21 12:32:45 [PicList ERROR] 插件安装失败,失败码为-2,错误日志为

2023-03-21 12:33:14 [PicList ERROR] ------Error Stack Begin------ Error: spawn npm ENOENT at ChildProcess._handle.onexit (node:internal/child_process:283:19) at onErrorNT (node:internal/child_process:478:16) at process.processTicksAndRejections (node:internal/process/task_queues:83:21) -------Error Stack End------- 2023-03-21 12:33:14 [PicList ERROR] NPM is not installed 2023-03-21 12:33:14 [PicList ERROR] 插件安装失败,失败码为-2,错误日志为

2023-03-21 12:33:17 [PicList INFO] [PicList Server] shutdown 2023-03-21 12:33:22 [PicList INFO] [PicList Server] is listening at 36677 2023-03-21 12:34:12 [PicList ERROR] ------Error Stack Begin------ Error: spawn npm ENOENT at ChildProcess._handle.onexit (node:internal/child_process:283:19) at onErrorNT (node:internal/child_process:478:16) at process.processTicksAndRejections (node:internal/process/task_queues:83:21) -------Error Stack End-------

我尝试了很多方法 ,但仍然没找到可以在沙盒内执行命令行的方法。。不过我找到了一个曲线救国的办法,安装插件的时候,现在会提示用户手动执行npm命令,我会给出具体的命令,执行完成后,点击已添加软件会自动在设置文件内更新插件信息。

这样起码是可以用的了,就是略繁琐了点。。
@wakewon

@wakewon
Copy link
Author

wakewon commented Mar 21, 2023

安装插件的时候,现在会提示用户手动执行npm命令,我会给出具体的命令,执行完成后,点击已添加软件会自动在设置文件内更新插件信息。

确实是一种可行的方法,看起来还是远离MAS保平安了
(不过从release里下载的包也还是有一样的界面问题)

@Kuingsmile
Copy link
Owner

安装插件的时候,现在会提示用户手动执行npm命令,我会给出具体的命令,执行完成后,点击已添加软件会自动在设置文件内更新插件信息。

确实是一种可行的方法,看起来还是远离MAS保平安了 (不过从release里下载的包也还是有一样的界面问题)

MAS的sandbox导致很多限制= _ =
界面问题应该是渲染上的问题,这个后面我修一修

Kuingsmile added a commit that referenced this issue Mar 21, 2023
@Kuingsmile
Copy link
Owner

新版本已修复,正在进行app store审核。

@Kuingsmile
Copy link
Owner

这里还有一个问题是左边栏和顶部有错位

@wakewon commit f0daf97已修复该问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants