Skip to content

Mason crashes Neovim with bad argument to fs_fstat #1815

@duhdugg

Description

@duhdugg

I've searched open issues for similar requests

  • Yes

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

  • Yes

Problem description

Using Mason command causes neovim to crash with error:

PANIC: unprotected error in call to Lua API (...ocal/share/nvim/plugged/mason.nvim/lua/mason-core/fs.lua:13: bad argument #1 to'fs_fstat' (number expected, got nil))

Expected behavior

neovim does not crash when using Mason commands

Steps to reproduce

On Wolfi OS with the following packages installed:

luajit (2.1_p20210510-r7)
lua5.1-lpeg (1.1.0-r1)
libuv (1.49.2-r0)
lua-luv (1.48.0.2-r2)
msgpack-c (6.1.0-r1)
tree-sitter (0.24.3-r0)
unibilium (2.1.2-r0)
neovim (0.10.2-r0)

init.vim (using plug.vim):

call plug#begin()
  Plug 'williamboman/mason.nvim'
call plug#end()

lua << EOF
  require("mason").setup()
EOF
  1. install nvim, plug.vim, :PlugInstall
  2. run :Mason command

Neovim version (>= 0.7)

NVIM v0.10.2
Build type: RelWithDebInfo
LuaJIT 2.1.0-beta3

Operating system/version

Linux 78e974240061 6.10.12-200.fc40.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Sep 30 21:38:25 UTC 2024 x86_64 Linux

Healthcheck output

running :checkhealth returns this same error:

PANIC: unprotected error in call to Lua API (...ocal/share/nvim/plugged/mason.nvim/lua/mason-core/fs.lua:13: bad argument #1 to'fs_fstat' (number expected, got nil))

Screenshots

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions