Skip to content

lua/intf/cli: commands like "get_time" give an error: attempt to index field 'player' (a nil value)

Kernel:   5.4.0-91-generic x86_64 
bits:     64 
compiler: gcc v: 9.3.0 
Desktop:  Cinnamon 5.0.7 
Distro:   Linux Mint 20.2 Uma 
base:     Ubuntu 20.04 focal 

distro repo:

$ vlc -vvv
VLC media player 3.0.9.2 Vetinari (revision 3.0.9.2-0-gd4c1aefe4d)

snap default:

$ vlc -vvv
VLC media player 3.0.16 Vetinari (revision 3.0.16-0-g5e70837d8d)

steps to reproduce:

  1. copy https://github.com/videolan/vlc/blob/master/share/lua/intf/cli.lua to ~/.local/share/vlc/lua/intf
  2. rename it, say, to cmd.lua
  3. launch vlc, point to "cmd" interface, restart from terminal, load a video, command: pause, OK
  4. command: is_playing, response:
Error in `is_playing' /home/***/.local/share/vlc/lua/intf/cmd.lua:377: attempt to index field 'player' (a nil value)
> 
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information