jdepoix / youtube-transcript-api

This is a python API which allows you to get the transcript/subtitles for a given YouTube video. It also works for automatically generated subtitles and it does not require an API key nor a headless browser, like other selenium based solutions do!
MIT License
2.87k stars 326 forks source link

the right timestamp formation is '00:00:06,930' not '00:00:06.930' #162

Closed lionderful closed 1 year ago

lionderful commented 2 years ago

"," in srt timestamp format, not "."

_seconds_to_timestamp should return "{:02.0f}:{:02.0f}:{:02.0f},{:03d}".format(hours, mins, secs, ms)

thank you, man. you have done a great help for me,

jdepoix commented 1 year ago

Hi @lionderful, we currently only have a WebVTT formatter, for which this format is correct. But as I see you already contributed a SRT formatter 🥳