glut23 / webvtt-py

Read, write, convert and segment WebVTT caption files in Python.
MIT License
188 stars 56 forks source link

add property to get webvtt content without needing a file #34

Closed DawoudSheraz closed 3 years ago

DawoudSheraz commented 3 years ago

Description

This PR adds a property content in WebVTT object to obtain the formatted vtt without the need to create a .vtt file on the system. This can be helpful in cases when the data needs to be saved on a remote server and not on the hosted server. The addition of property will remove the overhead of creating a temporary vtt file and then reading the content from it.

Unit Tests Result

image

DawoudSheraz commented 3 years ago

@glut23 Hello. Can you take a look and provide your thoughts? Thanks

DawoudSheraz commented 3 years ago

@glut23 Hi. Did you get a chance to look at this? Thank You

DawoudSheraz commented 3 years ago

@glut23 Hello. Pinging to get an update. Thank You

glut23 commented 3 years ago

Hey @DawoudSheraz apologies for not replying earlier. Having this is indeed useful and it would be good to add it in. I would use the class WebVTTWriter to do it. Also it would be great if you could have the docs also updated to reflect this new feature.

DawoudSheraz commented 3 years ago

Hey @DawoudSheraz apologies for not replying earlier. Having this is indeed useful and it would be good to add it in. I would use the class WebVTTWriter to do it. Also it would be great if you could have the docs also updated to reflect this new feature.

Sure, I will update the PR and the docs and then follow-up. Thanks

DawoudSheraz commented 3 years ago

@glut23 Hello. I have updated the code and addressed the comments. Please take a second look. Thank You

DawoudSheraz commented 3 years ago

@glut23 Thanks for the feedback. I have updated the code.

glut23 commented 3 years ago

Hey @DawoudSheraz I merged the code and I will prepare a release as soon as I can. Thanks for contributing!

DawoudSheraz commented 3 years ago

Hey @DawoudSheraz I merged the code and I will prepare a release as soon as I can. Thanks for contributing!

Glad to hear that, thank you.

glut23 commented 3 years ago

Hey @DawoudSheraz 0.4.6 is now released. Thanks.

DawoudSheraz commented 3 years ago

Awesome, thanks