Skip to content

Checkhealth fails to report luarocks version number #1646

@FerretDetective

Description

@FerretDetective

I've searched open issues for similar requests

  • Yes

I've recently downloaded the latest plugin version of mason.nvim

  • Yes

Problem description

When using a luarocks version with a minor version number which has more than one digit mason will fail to parse the version number.

Expected behavior

Mason should parse the version number of luarocks regardless of how many digits the minor version number is.

Steps to reproduce

  1. Install luarocks with a minor version number that has more than one digit (exg: 3.10.0)
  2. run :checkhealth mason

Neovim version (>= 0.7)

NVIM v0.9.5
Build type: Release
LuaJIT 2.1.1702233742

system vimrc file: "$VIM/sysinit.vim"
fall-back for $VIM: "/usr/share/nvim"

Run :checkhealth for more info

Operating system/version

Linux archlinux 6.7.8-arch1-1 #1 SMP PREEMPT_DYNAMIC Sun, 03 Mar 2024 00:30:36 +0000 x86_64 GNU/Linux

Healthcheck output

mason: require("mason.health").check()

mason.nvim ~
- OK mason.nvim version v1.10.0
- OK PATH: prepend
- 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-03-04-scarce-bonito` 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.4 built on linux-gnu.`
- OK curl: `curl 8.6.0 (x86_64-pc-linux-gnu) libcurl/8.6.0 OpenSSL/3.2.1 zlib/1.3.1 brotli/1.1.0 zstd/1.5.5 libidn2/2.3.7 libpsl/0.21.2 libssh2/1.11.0 nghttp2/1.60.0 nghttp3/1.2.0`
- OK gzip: `gzip 1.13`
- OK tar: `tar (GNU tar) 1.35`
- OK bash: `GNU bash, version 5.2.26(1)-release (x86_64-pc-linux-gnu)`
- OK sh: `Ok`

mason.nvim [Languages] ~
- OK Go: `go version go1.22.0 linux/amd64`
- OK Ruby: `ruby 3.0.6p216 (2023-03-30 revision 23a532679b) [x86_64-linux]`
- OK PHP: `PHP 8.3.3 (cli) (built: Feb 16 2024 17:14:40) (NTS)`
- WARNING luarocks: failed to parse version
  - ADVICE:
    - Error: ~/.local/share/nvim/lazy/mason.nvim/lua/mason/health.lua:214: attempt to compare number with nil
- OK node: `v21.6.2`
- OK cargo: `cargo 1.76.0 (c84b36747 2024-01-18)`
- OK Composer: `Composer version 2.7.1 2024-02-09 15:26:28`
- OK java: `openjdk version "21.0.2" 2024-01-16`
- OK RubyGem: `3.3.25`
- OK julia: `julia version 1.10.1`
- OK python: `Python 3.12.2`
- OK npm: `10.5.0`
- OK javac: `javac 21.0.2`
- OK pip: `pip 24.0 from ~/.pyenv/versions/3.12.2/lib/python3.12/site-packages/pip (python 3.12)`
- OK python venv: `Ok`

mason.nvim [GitHub] ~
- OK GitHub API rate limit. Used: 0. Remaining: 5000. Limit: 5000. Reset: Tue 05 Mar 2024 12:03:31 AM.

Screenshots

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions