Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

".." breaks script #24

Closed
altano opened this issue Jan 10, 2023 · 2 comments
Closed

".." breaks script #24

altano opened this issue Jan 10, 2023 · 2 comments

Comments

@altano
Copy link

altano commented Jan 10, 2023

Hey, first off thanks for making this script.

I am processing a large number of srt files and I got several errors. The common thing with all the blocks that cause errors are that they start and end in "..", like so:

387
00:23:08,086 --> 00:23:10,680

..but the way he
describes me...

This gives me the following error:

➜  subcleaner git:(master) python3 ./subcleaner.py --dry-run --library ~/Downloads/Star\ Trek\ -\ Voyager\ -\ Subtitles -r ~/Downloads/Star\ Trek\ -\ Voyager\ -\ Subtitles -e
   ERROR: subcleaner was unable to decode the file. reason:
   ERROR: Parsing error at block ..but the way he in file /Users/alan/Downloads/Star Trek - Voyager - Subtitles/Star_Trek_Voyager - season 7.en/Star Trek Voyager - 7x17 - Workforce  Part 2.DVD.en.srt.
@KBlixt
Copy link
Owner

KBlixt commented Jan 10, 2023

Will look into this asap

But from my initial view this seems to be a miss configured srt file.

Srt specifies that spaces are only allowed between blocks, not between the time stamp and the content.

I'll look into handling this though.

@KBlixt
Copy link
Owner

KBlixt commented Jan 10, 2023

I have implemented a more forgiving block splitter to allow for less well formatted srt files.

please verify that it works on your end as well now.

@KBlixt KBlixt closed this as completed Jan 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants