exebetche / vlsub

VLC extension to download subtitles from opensubtitles.org
1.35k stars 344 forks source link

Unable to save subtitles on Linux #213

Open devxpy opened 6 years ago

devxpy commented 6 years ago

The directory and the file, both are owned by me.

I ran a chown -R dev:dev /home/dev just to make sure.

This is the absolute path to file /home/dev/Downloads/Westworld.S01E10.avi

⋊ ~> vlc --version
VLC media player 3.0.2 Vetinari (revision 3.0.2-0-gd7b653cf14)
VLC version 3.0.2 Vetinari (3.0.2-0-gd7b653cf14)
Compiled by root on builder.solus-project.com (Apr 30 2018 13:00:12)
Compiler: gcc version 7.3.0 (Solus)

image

suzanshakya commented 6 years ago

I'm having the same issue on Arch linux (manjaro-i3).

ThatLurker commented 6 years ago

Seems like currently the only solution is to use the latest nightly version of vlc #214

fpontef commented 6 years ago

The nightly version of vlc have a different version of this same plugin.

While the latest version here is: https://github.com/exebetche/vlsub/blob/master/vlsub.lua local app_version = "0.10.2";

The real latest version is: https://github.com/videolan/vlc/blob/master/share/lua/extensions/VLSub.lua version = "0.11.0",

I tried to use the new plugin with older VLC but had some "vlc.io.names" errors, don't know how to fix, as the older uses "io.names" and just changing this won't work (VLC api changes maybe?). Didn't go further as I don't know Lua and missed where the "zip" changes from the old version.

devxpy commented 6 years ago

I really wish this was built on python, not Lua

gilelias commented 6 years ago

I had the same issue on ubuntu, I found out the the cache folder is missing. Creating the cache folder fixed the issue for me. mkdir ~/.cache/vlc

devxpy commented 6 years ago

I have the cache folder where it should be..

gvorster commented 6 years ago

@gilelias mkdir ~/.cache/vlc this did it for me on ubuntu 18

devxpy commented 6 years ago
⋊ ~> cd ~/.cache/vlc
⋊ ~/.c/vlc> ls
 art/
'Tomb.Raider.2018.720p.WEB-DL.H264.AC3-EVO (CHI).srt.gz'
 Tomb.Raider.2018.720p.WEB-DL.H264.AC3-EVO-HI.srt.gz
 Tomb.Raider.2018.720p.WEB-DL.H264.AC3-EVO.srt.gz
 Westworld.S02E08.720p.WEB.H264-DEFLATE.srt.gz
 Westworld.S02E09.720p.WEB.H264-DEFLATE.srt.gz
hexion commented 6 years ago

@gilelias worked like a charm, thanks!

canf commented 6 years ago

mkdir ~/.cache/vlc worked, thanks!

itai590 commented 6 years ago

mkdir ~/.cache/vlc Worked like a magic thanks!

sergiotca commented 6 years ago

What about VLC snap installs? will it still makes sense to create a ~/.cache/vlc in the home folder?? I am a complete noob when it comes to snaps but for all I can see they do not follow the same installation route as regular deb packages, they seem to create its own strcture under the ~/snap folder

MostafaMhmod commented 6 years ago

Try to make the .cache folder in the snap folder inside the common in the vlc folder. mkdir ~/snap/vlc/common/.cache @sergiotca

sergiotca commented 6 years ago

Hi Mostafa, I did figure that out a few weeks ago. It does work btw. Thank you anyway.

vagner-nascimento commented 6 years ago

I have tried all alternatives above without susscess in Ubuntu 18.04... i'll still waiting for a definitive solution.

thyagoleal commented 6 years ago

@gilelias This worked for me on Ubuntu 18.04

atay commented 6 years ago

I came here because I had issues with downloading subtitles (some of them worked, some not, gz file was downloaded, but subtitles were not found).

I found out that VLSub 0.11 assumes that opensubtitles SubFormat must be same as file extension, which is not correct for many records in opensubtitles.

I prepared a version with fix that searches for a file instead of extension and it works perfectly for me. If someone has same issue as I had, feel free to replace VLSub.luac file (located in /usr/lib/x86_64-linux-gnu/vlc/lua/extensions/VLSub.luac on ubuntu) with that one: https://mega.nz/#F!jHIhUIBY!Dm0p-QGaUnBGhckEl9JxUw

Also lua file included in case if someone would like to check/compile that file by himself.

rafiron commented 6 years ago

The same is happening to me on mac. Can someone guide on how to get it fixed there.

ThatLurker commented 6 years ago

@rafiron try switching to Iina it works awesome on mac and has subtitle download build in with multiple providers to choose from

agiratech-vigneshm commented 6 years ago

Ubuntu 18, Cache folder in ~/.cache/vlc did the trick for me.

alecco commented 6 years ago

@gilelias VLC downloads the .srt.gz but to ~/.config/vlc but then it hangs. Like it can't gunzip and copy. Gentoo 2.4.1

Jarshvor commented 6 years ago

@gilelias Thanks for this. Was annoyed by this for a while and finally stopped being lazy and looked into it.

recreating the .cache/vlc directory fixed the issue for me on arch.

how did you think to look for the cache folder? did you see it complain it was missing somewhere? wished the error for this had been more verbose.

pmaoui commented 6 years ago

Like @Jarshvor, I'm very interested to learn how @gilelias managed to find out this solution (which also did the trick for me).

gilelias commented 6 years ago

@Jarshvor @poupougnac I was debugging vlsub code and checked where and why mess_save_fail appears. I just realized that I have older version of vlsub. I guess https://github.com/exebetche/vlsub/commit/b3513c539b154c039ef7be8c9f54f68f3d5bd870 should fix the issue.

Jarshvor commented 6 years ago

I see.. so pretty much under the hood. =) thanks for that and for the info. Will keep it in mind for next time I encounter something similar.

iuliandonici commented 6 years ago

In Lubuntu 18.0.4.1 LTS, guys, for some reason I don't fully understand, creating the "cache" folder under the "root" user, VLC still wasn't loading my subtitles. Yet, when I've exited and re-created it under the user I've installed Lubuntu initially, mkdir ~/.cache/vlc worked like a charm.

Jarshvor commented 6 years ago

@iuliandonici well, makes sense if you are running vlc from that user account no?

if you start vlc from your normal user account (which you should) then it will look for the .cache folder in your home directory. i.e: ~

devxpy commented 6 years ago

Looks like this is fixed now on 3.0.4

It still displays an error, but it loads the subtitle, regardless.

Big thanks to @xpaum for the fix!

image

Appendix94 commented 6 years ago

@gilelias mkdir ~/.cache/vlc this did it for me on ubuntu 18

Also work for me on Fedora 27, vlc 3.0.5

julian-alarcon commented 6 years ago

I'm still getting this error with Ubuntu 18.04 and VLC from Snap version 3.0.4

darkhole@devolo:~$ snap info vlc
name:      vlc
summary:   The ultimate media player
publisher: VideoLAN✓
contact:   https://www.videolan.org/support/
license:   unset
description: |
  VLC is the VideoLAN project's media player.

  Completely open source and privacy-friendly, it plays every multimedia file
  and streams.

  It notably plays MKV, MP4, MPEG, MPEG-2, MPEG-4, DivX, MOV, WMV, QuickTime,
  WebM, FLAC, MP3, Ogg/Vorbis files, BluRays, DVDs, VCDs, podcasts, and
  multimedia streams from various network sources. It supports subtitles,
  closed captions and is translated in numerous languages.
commands:
  - vlc
snap-id:      RT9mcUhVsRYrDLG8qnvGiy26NKvv6Qkd
tracking:     stable
refresh-date: 2018-09-08
channels:                                        
  stable:    3.0.4                   (555) 204MB -
  candidate: 3.0.4                   (555) 204MB -
  beta:      3.0.4-224-gffb4ac0      (694) 212MB -
  edge:      4.0.0-dev-5362-gaf740a6 (695) 247MB -
installed:   3.0.4                   (555) 204MB -

VLsub, according to the window, is version 0.11.0

efinley1272 commented 6 years ago

+1 ubuntu desktop 18.04.1 snap VLC 3.0.4 vlsub 0.11.0 ~/.cache/vlc exists and is owned by me, has rwx permissions ~/snap/vlc/common/.cache exists and is owned by me, has rwx permissions

still getting the "Error: Unable to save subtitles Click here to open the file"

EDIT: Also, just tried the edge: 4.0.0-dev-5377-g0667915 snap and still get the same issue.

devxpy commented 6 years ago

Ok will reopen this...

PetriKoo commented 6 years ago

I´ve noticed that the problem is getting file from opensubtitles server

ghost commented 5 years ago

I also missed the cache folder. Creating it fixed the issue on Kubuntu 18.10

But....had somebody reported that upstream? It has been 7 months since the bug was reported

ghost commented 5 years ago

I reported it upstream

medjo commented 5 years ago

+1 ubuntu desktop 18.04.1 snap VLC 3.0.4 vlsub 0.11.0 ~/.cache/vlc exists and is owned by me, has rwx permissions ~/snap/vlc/common/.cache exists and is owned by me, has rwx permissions still getting the "Error: Unable to save subtitles Click here to open the file" EDIT: Also, just tried the edge: 4.0.0-dev-5377-g0667915 snap and still get the same issue.

Same as this, even with vlc 3.0.5

Same as this with vlc 3.0.6

indigopsy commented 5 years ago

I had the same issue on ubuntu, I found out the the cache folder is missing. Creating the cache folder fixed the issue for me. mkdir ~/.cache/vlc

good workaround

this trick also helps on: Distributor ID: Ubuntu Description: Ubuntu 18.10 Release: 18.10 Codename: cosmic

varunkamani commented 5 years ago

I had the same issue on ubuntu, I found out the the cache folder is missing. Creating the cache folder fixed the issue for me. mkdir ~/.cache/vlc

Thanks

thiagovilla commented 5 years ago

In Lubuntu 18.0.4.1 LTS, guys, for some reason I don't fully understand, creating the "cache" folder under the "root" user, VLC still wasn't loading my subtitles. Yet, when I've exited and re-created it under the user I've installed Lubuntu initially, mkdir ~/.cache/vlc worked like a charm.

Worked for me!

mads2 commented 5 years ago

Problem persist on a fresh Raspbian install followed by apt update & apt upgrade and apt install vlc. Raspbian 9 (stretch) 4.14.98-v7+ VLC 3.0.6 Vetinari

mkdir ~/.cache/vlc fixed it though.

samomar commented 5 years ago

For anyone still having problems if mkdir ~/.cache/vlc did not work with you.

try mkdir ~/snap/vlc/common/.cache/vlc

That worked for me since I installed VLC via snap, alternatively try to find where your VLC folder is and create a vlc folder inside the .cache folder.

Cheers

pacho2 commented 5 years ago

The directory is present and I can see some .gz files there... but it seems they fail to be extracted and, hence, it still gets stuck

sanderjo commented 5 years ago

Happens with VLC 3.0.6 on Ubuntu 19.04

The workaround mkdir ~/.cache/vlc works! Thank you!

subhant5 commented 5 years ago

For people who still have the issue, just goto home/snap/vlc/common/.cache folder and delete the vlc folder there and then make a new folder name it vlc. I hope that'll work. :)

MitulPanchal commented 5 years ago

Thanks works fine with: mkdir ~/snap/vlc/common/.cache/vlc

First i try this on my ubuntu 18.04 but didn't work. mkdir ~/.cache/vlc did not work with you

sanderjo commented 5 years ago

Thanks works fine with: mkdir ~/snap/vlc/common/.cache/vlc

First i try this on my ubuntu 18.04 but didn't work. mkdir ~/.cache/vlc did not work with you

So ... I guess you're running VLC as / from a snap package ... ?

MitulPanchal commented 5 years ago

@sanderjo yes i checked and it is from snap package

ilansh commented 5 years ago

For anyone still having problems if mkdir ~/.cache/vlc did not work with you.

try mkdir ~/snap/vlc/common/.cache/vlc

That worked for me since I installed VLC via snap, alternatively try to find where your VLC folder is and create a vlc folder inside the .cache folder.

Cheers

Worked for me, the missing part was to create vlc directory inside .cache

jagzmz commented 5 years ago

For anyone still having problems if mkdir ~/.cache/vlc did not work with you.

try mkdir ~/snap/vlc/common/.cache/vlc

That worked for me since I installed VLC via snap, alternatively try to find where your VLC folder is and create a vlc folder inside the .cache folder.

Cheers

This worked for me!

stripathi669 commented 5 years ago

For anyone still having problems if mkdir ~/.cache/vlc did not work with you. try mkdir ~/snap/vlc/common/.cache/vlc That worked for me since I installed VLC via snap, alternatively try to find where your VLC folder is and create a vlc folder inside the .cache folder. Cheers

Worked for me, the missing part was to create vlc directory inside .cache

Ubuntu 18.04, vlc 3.0.6 - deleting and recreating worked for me.