pikaraoke icon indicating copy to clipboard operation
pikaraoke copied to clipboard

XDG_RUNTIME_DIR error on VLC when playing videos

Open troy-lim opened this issue 3 years ago • 16 comments

Output of pikaraoke.log:

[2022-01-30 02:03:17] INFO: Fetching available songs in: /root/pikaraoke-songs/ [2022-01-30 02:03:18] INFO: VLC command base: /usr/bin/vlc -f --play-and-exit --extraintf http --http-port 5002 --http-password kuIo8Z1FWRj6Jjp5g1EDHNVb5eBVccoK --no-embedded-video --no-keyboard-events --no-mouse-events --mouse-hide-timeout 0 --video-on-top --no-video-title --mouse-hide-timeout 0 [30/Jan/2022:02:03:18] ENGINE Bus STARTING [2022-01-30 02:03:18] INFO: [30/Jan/2022:02:03:18] ENGINE Bus STARTING [30/Jan/2022:02:03:18] ENGINE Started monitor thread '_TimeoutMonitor'. [2022-01-30 02:03:18] INFO: [30/Jan/2022:02:03:18] ENGINE Started monitor thread '_TimeoutMonitor'. [30/Jan/2022:02:03:18] ENGINE Serving on http://0.0.0.0:5000 [2022-01-30 02:03:18] INFO: [30/Jan/2022:02:03:18] ENGINE Serving on http://0.0.0.0:5000 [30/Jan/2022:02:03:18] ENGINE Bus STARTED [2022-01-30 02:03:18] INFO: [30/Jan/2022:02:03:18] ENGINE Bus STARTED [2022-01-30 02:03:18] INFO: Starting PiKaraoke! [2022-01-30 02:03:33] INFO: 'Chewbacca' is adding song to queue: /root/pikaraoke-songs/A-ha - The Sun Always Shines On T.V. - Karaoke Version from Zoom Karaoke---_XVjhOHZuiY.mp4 [2022-01-30 02:03:39] INFO: Playing video in VLC: A-ha - The Sun Always Shines On T.V. - Karaoke Version from Zoom Karaoke [00005619f604f480] vlcpulse audio output error: PulseAudio server connection failure: Connection refused [00005619f60e7930] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11 [00005619f60e7930] main interface error: no suitable interface module [00005619f5fae570] main libvlc error: interface "dbus,none" initialization failed [00005619f60e7930] [http] lua interface: Lua HTTP interface [00005619f607d8f0] main interface error: no suitable interface module [00005619f5fae570] main libvlc error: interface "globalhotkeys,none" initialization failed [00005619f5fae570] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. error: XDG_RUNTIME_DIR not set in the environment. [00005619f607d8f0] skins2 interface error: cannot initialize OSFactory [00005619f607d8f0] [cli] lua interface: Listening on host "*console". VLC media player 3.0.12 Vetinari Command Line Interface initialized. Type `help' for help.

error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment. [00007f3a74001370] gl vout display error: parent window not available [00007f3a74001370] gles2 vout display error: parent window not available [00007f3a74001370] xcb vout display error: window not available

[2022-01-30 02:03:53] INFO: Clearing queue! [2022-01-30 02:03:53] WARNING: Tried to skip, but no file is playing! [30/Jan/2022:02:03:53] ENGINE Bus STOPPING [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus STOPPING [30/Jan/2022:02:03:53] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) shut down [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) shut down [30/Jan/2022:02:03:53] ENGINE Stopped thread '_TimeoutMonitor'. [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Stopped thread '_TimeoutMonitor'. [30/Jan/2022:02:03:53] ENGINE Bus STOPPED [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus STOPPED [30/Jan/2022:02:03:53] ENGINE Bus STOPPING [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus STOPPING [30/Jan/2022:02:03:53] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) already shut down [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) already shut down [30/Jan/2022:02:03:53] ENGINE No thread running for None. [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE No thread running for None. [30/Jan/2022:02:03:53] ENGINE Bus STOPPED [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus STOPPED [30/Jan/2022:02:03:53] ENGINE Bus EXITING [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus EXITING [30/Jan/2022:02:03:53] ENGINE Bus EXITED [2022-01-30 02:03:53] INFO: [30/Jan/2022:02:03:53] ENGINE Bus EXITED [30/Jan/2022:02:03:54] ENGINE Bus STOPPING [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE Bus STOPPING [30/Jan/2022:02:03:54] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) already shut down [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 5000)) already shut down [30/Jan/2022:02:03:54] ENGINE No thread running for None. [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE No thread running for None. [30/Jan/2022:02:03:54] ENGINE Bus STOPPED [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE Bus STOPPED [30/Jan/2022:02:03:54] ENGINE Bus EXITING [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE Bus EXITING [30/Jan/2022:02:03:54] ENGINE Bus EXITED [2022-01-30 02:03:54] INFO: [30/Jan/2022:02:03:54] ENGINE Bus EXITED pygame 1.9.6 Hello from the pygame community. https://www.pygame.org/contribute.html

But, if I run /usr/bin/vlc -f /home/pi/pikaraoke-songs/filename.mp4 The video plays.

(Yes, my username is pi eventhough it's installed on an x86 machine :)) I also created a symlink of /root/pikaraoke-songs to /home/pi/pikaraoke-songs and made the directories accessible.

troy-lim avatar Jan 29 '22 18:01 troy-lim

I've encountered what I believe to be similar errors running on a RPi4 (specifically the "vlcpulse audio output error" and the dbus interface error following it in your log). I've not yet found a cause or workaround but I noticed that if I launch the pikaraoke app from power-up (using \etc\rc.local) it usually works, but if I quit back to the pi desktop and re-run from the CLI in a shell window, with exactly the same command that worked from rc.local, the app runs and videos play but there's no sound. At that point, if I run VLC directly the videos play with audio working fine. It's as if there's an explicit audio option or parameter missing from the vlc command within the app, similar in purpose to the -a option provided for omxplayer. It defaults correctly from rc.local launch of the pikaraoke app, and from direct VLC launch from desktop, but defaults to some other audio when pikaraoke gets re-launched after quitting. Apologies if this turns out to be a different issue, but there seem to be enough parallels to make it relevant.

Hartebee5t avatar Jan 30 '22 13:01 Hartebee5t

In my case, if I run "/usr/bin/vlc -f /home/pi/pikaraoke-songs/filename.mp4" the video plays without any problem but after the video is done playing I see something like this:

VLC media player 3.0.12 Vetinari (revision 3.0.12-1-0-gd147bb5e7e) [00005594927d6f10] main interface error: no suitable interface module [00005594926f2570] main libvlc error: interface "globalhotkeys,none" initialization failed [00005594926f2570] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. [00005594927d6f10] skins2 interface error: cannot initialize OSFactory [00005594927d6f10] [cli] lua interface: Listening on host "*console". VLC media player 3.0.12 Vetinari Command Line Interface initialized. Type `help' for help. [00007f218c001370] gl vout display error: parent window not available [00007f218c001370] gles2 vout display error: parent window not available [00007f218c001370] xcb vout display error: window not available

Then I have to type ctrl+C to terminate vlc.

Gong back to PiKaraoke, if I run "sudo python3 app.py", the web interface is working as it should. Search and download is working, also queueing. But after queue, the song shows up in the Home tab but only for a few seconds as if it played and finished the song.

I also tried to launch the app from power-up (using systemctl .service) but, alas! I still get the same result. :(

troy-lim avatar Jan 31 '22 08:01 troy-lim

Just to be clear, you're running on linux? Have you tried without running python3 app.py without sudo?

vicwomg avatar Jan 31 '22 17:01 vicwomg

Just to be clear, you're running on linux?

Yes. Debian Buster on an Intel atom.

troy-lim avatar Jan 31 '22 22:01 troy-lim

this is probably because you ran once as sudo and it generated the qrcode with root permissions. If you sudo rm /home/pi/pikaraoke/qrcode.png then try again you should get further

vicwomg avatar Jan 31 '22 22:01 vicwomg

Have you tried without running python3 app.py without sudo?

IMG20220201064326.jpg

troy-lim avatar Jan 31 '22 22:01 troy-lim

this is probably because you ran once as sudo and it generated the qrcode with root permissions. If you sudo rm /home/pi/pikaraoke/qrcode.png then try again you should get further

It says unable to open mouse.

IMG20220201072341.jpg

troy-lim avatar Jan 31 '22 23:01 troy-lim

Ok, back to sudo then, pygame is being restrictive... especially when running in a non-desktop environment, which sounds familiar. Did you try patching vlc so that it can run as sudo? As it turns out, this is a necessary step in the pi installations:

sed -i 's/geteuid/getppid/' /usr/bin/vlc

vicwomg avatar Jan 31 '22 23:01 vicwomg

Ok, back to sudo then, pygame is being restrictive... especially when running in a non-desktop environment, which sounds familiar. Did you try patching vlc so that it can run as sudo? As it turns out, this is a necessary step in the pi installations:

sed -i 's/geteuid/getppid/' /usr/bin/vlc

Yes I did. I can launch vlc as root.

troy-lim avatar Jan 31 '22 23:01 troy-lim

Then I am at a loss, hopefully someone with more direct Linux experience can chime in

vicwomg avatar Feb 01 '22 00:02 vicwomg

Then I am at a loss, hopefully someone with more direct Linux experience can chime in

Thank you so much for the effort. Hope that someone out there can give some light into this. I'm running out of space in my RasPi-Pikaraoke. :)

troy-lim avatar Feb 04 '22 03:02 troy-lim

Okay, here's what I've noticed.

PLAYING f251.webm (Audio only fIle) - Audio plays well (Splash screen showing) Here's the output:

pi@happykaraoke:~$ sudo /usr/bin/python3 /home/pi/pikaraoke/app.py pygame 1.9.6 Hello from the pygame community. https://www.pygame.org/contribute.html [2022-03-03 15:35:41] INFO: Fetching available songs in: /root/pikaraoke-songs/ [2022-03-03 15:35:44] INFO: VLC command base: /usr/bin/vlc -f --play-and-exit --extraintf http --http-port 5002 --http-password s7ayOXSKA445j4dO9Rrg2gXRys4ahwcq --no-embedded-video --no-keyboard-events --no-mouse-events --mouse-hide-timeout 0 --video-on-top --no-video-title [03/Mar/2022:15:35:45] ENGINE Bus STARTING [2022-03-03 15:35:45] INFO: [03/Mar/2022:15:35:45] ENGINE Bus STARTING [03/Mar/2022:15:35:45] ENGINE Started monitor thread '_TimeoutMonitor'. [2022-03-03 15:35:45] INFO: [03/Mar/2022:15:35:45] ENGINE Started monitor thread '_TimeoutMonitor'. [03/Mar/2022:15:35:45] ENGINE Serving on http://0.0.0.0:5000 [2022-03-03 15:35:45] INFO: [03/Mar/2022:15:35:45] ENGINE Serving on http://0.0.0.0:5000 [03/Mar/2022:15:35:45] ENGINE Bus STARTED [2022-03-03 15:35:45] INFO: [03/Mar/2022:15:35:45] ENGINE Bus STARTED [2022-03-03 15:35:45] INFO: Starting PiKaraoke! [2022-03-03 15:36:17] INFO: 'Chewbacca' is adding song to queue: /root/pikaraoke-songs/Atomic/EXTREME - More than words (Karaoke Version)---J1SiPYj9SaU.f251.webm [2022-03-03 15:36:23] INFO: Playing video in VLC: EXTREME - More than words (Karaoke Version) VLC media player 3.0.16 Vetinari (revision 3.0.13-8-g41878ff4f2) [000055a6216d5390] vlcpulse audio output error: PulseAudio server connection failure: Connection refused [000055a62170afb0] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11 [000055a62170afb0] main interface error: no suitable interface module [000055a6215fe5b0] main libvlc error: interface "dbus,none" initialization failed [000055a62170afb0] [http] lua interface: Lua HTTP interface [000055a6217659f0] main interface error: no suitable interface module [000055a6215fe5b0] main libvlc error: interface "globalhotkeys,none" initialization failed [000055a6215fe5b0] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. error: XDG_RUNTIME_DIR not set in the environment. [000055a6217659f0] skins2 interface error: cannot initialize OSFactory [000055a6217659f0] [cli] lua interface: Listening on host "*console". VLC media player 3.0.16 Vetinari Command Line Interface initialized. Type `help' for help. [000055a621698400] main playlist: end of playlist, exiting [000055a6217659f0] [cli] lua interface error: Error loading script /usr/lib/x86_64-linux-gnu/vlc/lua/intf/cli.luac: lua/intf/modules/host.lua:289: Interrupted.

PLAYING f243.webm (Video Only File) - Does not play. Here's the output:

pi@happykaraoke:~$ sudo /usr/bin/python3 /home/pi/pikaraoke/app.py pygame 1.9.6 Hello from the pygame community. https://www.pygame.org/contribute.html [2022-03-03 15:43:36] INFO: Fetching available songs in: /root/pikaraoke-songs/ [2022-03-03 15:43:39] INFO: VLC command base: /usr/bin/vlc -f --play-and-exit --extraintf http --http-port 5002 --http-password IJ5H9M0Af4AX0ACoMCWa5Mg72Q3iKKDz --no-embedded-video --no-keyboard-events --no-mouse-events --mouse-hide-timeout 0 --video-on-top --no-video-title [03/Mar/2022:15:43:40] ENGINE Bus STARTING [2022-03-03 15:43:40] INFO: [03/Mar/2022:15:43:40] ENGINE Bus STARTING [03/Mar/2022:15:43:40] ENGINE Started monitor thread '_TimeoutMonitor'. [2022-03-03 15:43:40] INFO: [03/Mar/2022:15:43:40] ENGINE Started monitor thread '_TimeoutMonitor'. [03/Mar/2022:15:43:40] ENGINE Serving on http://0.0.0.0:5000 [2022-03-03 15:43:40] INFO: [03/Mar/2022:15:43:40] ENGINE Serving on http://0.0.0.0:5000 [03/Mar/2022:15:43:40] ENGINE Bus STARTED [2022-03-03 15:43:40] INFO: [03/Mar/2022:15:43:40] ENGINE Bus STARTED [2022-03-03 15:43:40] INFO: Starting PiKaraoke! [2022-03-03 15:44:01] INFO: 'Chewbacca' is adding song to queue: /root/pikaraoke-songs/Atomic/EXTREME - More than words (Karaoke Version)---J1SiPYj9SaU.f243.webm [2022-03-03 15:44:06] INFO: Playing video in VLC: EXTREME - More than words (Karaoke Version) VLC media player 3.0.16 Vetinari (revision 3.0.13-8-g41878ff4f2) [00005644831c43c0] vlcpulse audio output error: PulseAudio server connection failure: Connection refused [00005644831d6710] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11 [00005644831d6710] main interface error: no suitable interface module [00005644830ed5b0] main libvlc error: interface "dbus,none" initialization failed [00005644831d6710] [http] lua interface: Lua HTTP interface [00005644831f9fd0] main interface error: no suitable interface module [00005644830ed5b0] main libvlc error: interface "globalhotkeys,none" initialization failed [00005644830ed5b0] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. error: XDG_RUNTIME_DIR not set in the environment. [00005644831f9fd0] skins2 interface error: cannot initialize OSFactory [00005644831f9fd0] [cli] lua interface: Listening on host "*console". VLC media player 3.0.16 Vetinari Command Line Interface initialized. Type `help' for help. error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment. [00007f60580013b0] gl vout display error: parent window not available [00007f60580013b0] gles2 vout display error: parent window not available [00007f60580013b0] xcb vout display error: window not available

PLAYING .mp4 (Audio+Video) - Does not play. Here's the output:

pi@happykaraoke:~$ sudo /usr/bin/python3 /home/pi/pikaraoke/app.py pygame 1.9.6 Hello from the pygame community. https://www.pygame.org/contribute.html [2022-03-03 15:44:56] INFO: Fetching available songs in: /root/pikaraoke-songs/ [2022-03-03 15:45:00] INFO: VLC command base: /usr/bin/vlc -f --play-and-exit --extraintf http --http-port 5002 --http-password T2Btyo3fDzSRpFRfXuEgeLswEEMMPte8 --no-embedded-video --no-keyboard-events --no-mouse-events --mouse-hide-timeout 0 --video-on-top --no-video-title [03/Mar/2022:15:45:00] ENGINE Bus STARTING [2022-03-03 15:45:00] INFO: [03/Mar/2022:15:45:00] ENGINE Bus STARTING [03/Mar/2022:15:45:00] ENGINE Started monitor thread '_TimeoutMonitor'. [2022-03-03 15:45:00] INFO: [03/Mar/2022:15:45:00] ENGINE Started monitor thread '_TimeoutMonitor'. [03/Mar/2022:15:45:00] ENGINE Serving on http://0.0.0.0:5000 [2022-03-03 15:45:00] INFO: [03/Mar/2022:15:45:00] ENGINE Serving on http://0.0.0.0:5000 [03/Mar/2022:15:45:00] ENGINE Bus STARTED [2022-03-03 15:45:00] INFO: [03/Mar/2022:15:45:00] ENGINE Bus STARTED [2022-03-03 15:45:00] INFO: Starting PiKaraoke! [2022-03-03 15:45:15] INFO: 'Chewbacca' is adding song to queue: /root/pikaraoke-songs/ZoomKaraoke/Extreme - More Than Words (With Harmony) - Karaoke Version from Zoom Karaoke---rD2G1xU7hgs.mp4 [2022-03-03 15:45:20] INFO: Playing video in VLC: Extreme - More Than Words (With Harmony) - Karaoke Version from Zoom Karaoke VLC media player 3.0.16 Vetinari (revision 3.0.13-8-g41878ff4f2) [0000557711834390] vlcpulse audio output error: PulseAudio server connection failure: Connection refused [0000557711869fb0] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11 [0000557711869fb0] main interface error: no suitable interface module [000055771175d5b0] main libvlc error: interface "dbus,none" initialization failed [0000557711869fb0] [http] lua interface: Lua HTTP interface [00005577118c49f0] main interface error: no suitable interface module [000055771175d5b0] main libvlc error: interface "globalhotkeys,none" initialization failed [000055771175d5b0] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. error: XDG_RUNTIME_DIR not set in the environment. [00005577118c49f0] skins2 interface error: cannot initialize OSFactory [00005577118c49f0] [cli] lua interface: Listening on host "*console". VLC media player 3.0.16 Vetinari Command Line Interface initialized. Type `help' for help. error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment. [00007f87e40013b0] gl vout display error: parent window not available [00007f87e40013b0] gles2 vout display error: parent window not available [00007f87e40013b0] xcb vout display error: window not available

PLAYING MP3+CDG (Audio+Video) On SSH: Plays the audio and sends the video to the remote ssh as ASCII art. Locally: Plays the audio and plays the video on the console also as ASCII art. Here's the output:

pi@happykaraoke:~$ sudo /usr/bin/python3 /home/pi/pikaraoke/app.py pygame 1.9.6 Hello from the pygame community. https://www.pygame.org/contribute.html [2022-03-03 15:47:02] INFO: Fetching available songs in: /root/pikaraoke-songs/ [2022-03-03 15:47:05] INFO: VLC command base: /usr/bin/vlc -f --play-and-exit --extraintf http --http-port 5002 --http-password vzxmdKHCS5hfbLbHPQMGVSezagAWbC0s --no-embedded-video --no-keyboard-events --no-mouse-events --mouse-hide-timeout 0 --video-on-top --no-video-title [03/Mar/2022:15:47:06] ENGINE Bus STARTING [2022-03-03 15:47:06] INFO: [03/Mar/2022:15:47:06] ENGINE Bus STARTING [03/Mar/2022:15:47:06] ENGINE Started monitor thread '_TimeoutMonitor'. [2022-03-03 15:47:06] INFO: [03/Mar/2022:15:47:06] ENGINE Started monitor thread '_TimeoutMonitor'. [03/Mar/2022:15:47:06] ENGINE Serving on http://0.0.0.0:5000 [2022-03-03 15:47:06] INFO: [03/Mar/2022:15:47:06] ENGINE Serving on http://0.0.0.0:5000 [03/Mar/2022:15:47:06] ENGINE Bus STARTED [2022-03-03 15:47:06] INFO: [03/Mar/2022:15:47:06] ENGINE Bus STARTED [2022-03-03 15:47:06] INFO: Starting PiKaraoke! [2022-03-03 15:47:35] INFO: 'Chewbacca' is adding song to queue: /root/pikaraoke-songs/CDG/Sunfly/Sunfly Decades 90´s (SFD) (Karaoke Req)/SFD901-06/SFD901-06-08 - Extreme - More Than Words.mp3 [2022-03-03 15:47:40] INFO: Playing video in VLC: SFD901-06-08 - Extreme - More Than Words VLC media player 3.0.16 Vetinari (revision 3.0.13-8-g41878ff4f2) [00005629ba1943c0] vlcpulse audio output error: PulseAudio server connection failure: Connection refused [00005629ba1a6710] dbus interface error: Failed to connect to the D-Bus session daemon: Unable to autolaunch a dbus-daemon without a $DISPLAY for X11 [00005629ba1a6710] main interface error: no suitable interface module [00005629ba0bd5b0] main libvlc error: interface "dbus,none" initialization failed [00005629ba1a6710] [http] lua interface: Lua HTTP interface [00005629ba1c9fd0] main interface error: no suitable interface module [00005629ba0bd5b0] main libvlc error: interface "globalhotkeys,none" initialization failed [00005629ba0bd5b0] main libvlc: Running vlc with the default interface. Use 'cvlc' to use vlc without interface. error: XDG_RUNTIME_DIR not set in the environment. [00005629ba1c9fd0] skins2 interface error: cannot initialize OSFactory [00005629ba1c9fd0] [cli] lua interface: Listening on host "*console". VLC media player 3.0.16 Vetinari Command Line Interface initialized. Type `help' for help. error: XDG_RUNTIME_DIR not set in the environment. error: XDG_RUNTIME_DIR not set in the environment. [00007fde140013b0] gl vout display error: parent window not available [00007fde140013b0] gles2 vout display error: parent window not available [00007fde140013b0] xcb vout display error: window not available [00007fde140013b0] xcb vout display error: window not available

CDGPlayingSSH

I've noticed that there is always an XDG_RUNTIME_DIR error. I tried adding the username to the 'video' group and adding Defaults env_keep += "https_proxy" to sudoers and still no luck.

troy-lim avatar Mar 03 '22 10:03 troy-lim

So, I think we might want to be using cvlc instead of vlc, which avoids it trying to start the interface.

Also if you get the Ascii art display, you need to pass DISPLAY=:0 to force it to not try and draw in the current terminal.

tbelaire avatar Apr 28 '22 18:04 tbelaire

So, I think we might want to be using cvlc instead of vlc, which avoids it trying to start the interface.

I tried using clvc but the result is still the same.

Also if you get the Ascii art display, you need to pass DISPLAY=:0 to force it to not try and draw in the current terminal.

Do you have any idea on how to do this? I tried different methods but I can't seem to get it right.

troy-lim avatar May 11 '22 05:05 troy-lim

I'm using systemd to run on boot

https://github.com/tbelaire/pikaraoke/blob/service/pikaraoke.service#L16

And I added it to the ENV.

But I think you could do something with os.environ["DISPLAY"] = ":0" from inside the process.

If running directly, it would be

DISPLAY=:0 python app.py

tbelaire avatar May 11 '22 14:05 tbelaire

Have you tried without running python3 app.py without sudo?

IMG20220201064326.jpg

Hi, I had a similar issue running without sudo, but running with sudo wouldn't load sound. I found that if you just made the user the owner of the qrcode file and run without sudo, it works. I am on ubuntu, and I did chmod sudo chown user qrcode.png then launched without sudo and it worked. Maybe give it a try?

Teamustu avatar Jun 04 '22 06:06 Teamustu

VLC has been deprecated from Pikaraoke 1.2

vicwomg avatar Dec 24 '23 08:12 vicwomg