Git Product home page Git Product logo

Comments (4)

alexya avatar alexya commented on August 24, 2024

I met a similar issue to you. The following is from the MasonLog,

[ERROR Wed Apr 17 16:26:34 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:249: Installation failed for Package(name=tailwindcss-language-server) error=spawn: npm failed with exit code 1 and signal 0. 
[INFO  Wed Apr 17 16:26:34 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:184: Executing installer for Package(name=lua-language-server) {}
[ERROR Wed Apr 17 16:26:34 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:249: Installation failed for Package(name=html-lsp) error=spawn: npm failed with exit code 1 and signal 0. 
[INFO  Wed Apr 17 16:26:34 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:184: Executing installer for Package(name=graphql-language-service-cli) {}
[ERROR Wed Apr 17 16:26:34 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:249: Installation failed for Package(name=css-lsp) error=spawn: npm failed with exit code 1 and signal 0. 

But I can't find the log of Mason output e.g. under the folder /Users/<user_name>/.local/share/nvim/mason/staging/

from mason.nvim.

devd79 avatar devd79 commented on August 24, 2024

Same issue. Tried enabling debug mode in mason, but ERROR message is no more informative.

[DEBUG Thu Apr 25 16:44:35 2024] ...al/share/nvim/lazy/mason.nvim/lua/mason-core/process.lua:162: Spawned with pid 4168558
[DEBUG Thu Apr 25 16:44:35 2024] ...al/share/nvim/lazy/mason.nvim/lua/mason-core/process.lua:148: Job pid=4168558 exited with exit_code=1, signal=0
[DEBUG Thu Apr 25 16:44:35 2024] .../.local/share/nvim/lazy/mason.nvim/lua/mason-core/fs.lua:59: fs: unlink /home/devd/.local/share/nvim/mason/staging/pyright.lock
[DEBUG Thu Apr 25 16:44:35 2024] .../.local/share/nvim/lazy/mason.nvim/lua/mason-core/fs.lua:47: fs: rmrf /home/devd/.local/share/nvim/mason/staging/pyright
[DEBUG Thu Apr 25 16:44:35 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:39: Building receipt for Package(name=pyright)
[ERROR Thu Apr 25 16:44:35 2024] ...e/nvim/lazy/mason.nvim/lua/mason-core/installer/init.lua:249: Installation failed for Package(name=pyright) error=spawn: npm failed with exit code 1 and signal 0.

Healthcheck


- OK mason.nvim version v1.10.0
- OK PATH: skip
- OK Providers: 
  mason.providers.registry-api
  mason.providers.client
- OK neovim version >= 0.7.0

mason.nvim [Registries] ~
- OK Registry `github.com/mason-org/mason-registry version: 2024-04-25-cleaver-mitten` is installed.

mason.nvim [Core utils] ~
- OK unzip: `UnZip 6.00 of 20 April 2009, by Info-ZIP.  Maintained by C. Spieler.  Send`
- OK wget: `GNU Wget 1.21.1 built on linux-gnu.`
- OK curl: `curl 8.6.0 (x86_64-pc-linux-gnu) libcurl/8.6.0 OpenSSL/1.1.1k-fips zlib/1.2.11 zstd/1.4.4 libidn2/2.2.0 libpsl/0.20.2 nghttp2/1.43.0`
- OK gzip: `gzip 1.9`
- OK gtar: `tar (GNU tar) 1.30`
- OK bash: `GNU bash, version 4.4.20(1)-release (x86_64-redhat-linux-gnu)`
- OK sh: `Ok`

mason.nvim [Languages] ~
- WARNING cargo: not available
  - ADVICE:
    - spawn: cargo failed with exit code - and signal -. cargo is not executable
- WARNING Composer: not available
  - ADVICE:
    - spawn: composer failed with exit code - and signal -. composer is not executable
- WARNING PHP: not available
  - ADVICE:
    - spawn: php failed with exit code - and signal -. php is not executable
- WARNING luarocks: not available
  - ADVICE:
    - spawn: luarocks failed with exit code - and signal -. luarocks is not executable
- OK Ruby: `ruby 2.5.9p229 (2021-04-05 revision 67939) [x86_64-linux]`
- OK node: `v20.10.0`
- OK Go: `go version go1.22.1 linux/amd64`
- WARNING julia: not available
  - ADVICE:
    - spawn: julia failed with exit code - and signal -. julia is not executable
- OK python: `Python 3.11.6`
- OK RubyGem: `2.7.6.3`
- OK java: `openjdk version "1.8.0_362"`
- OK javac: `Ok`
- OK npm: `10.2.3`
- OK pip: `pip 23.3.1 from /app/vbuild/RHEL8-x86_64/python/3.11-addons-pip-23.3.1/lib/python3.11/site-packages/pip (python 3.11)`
- OK python venv: `Ok`

from mason.nvim.

devd79 avatar devd79 commented on August 24, 2024

Figured out! It was due to proxy. I ran the below command outside nvim,
npm install pyright and it clearly showed me the error :)

from mason.nvim.

mochouaaaaa avatar mochouaaaaa commented on August 24, 2024

I've encountered it and solved it, you guys can refer to it.

  1. I changed the .npm file registry, and when I restored the defaults, the error code became 243.
  2. Executing npm install XXX in the terminal prompted me to execute the following command, at which point my npm worked fine
sudo chown -R 501:20 $HOME/.npm

from mason.nvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.