pbs / pycaption

Python module to read/write popular video caption formats
Apache License 2.0
256 stars 136 forks source link

Add python3 compatibility. #185

Closed virtosubogdan closed 5 years ago

virtosubogdan commented 5 years ago

Made to look as much as possible to the master branch (version>1, python3 only)

andreipradan commented 5 years ago

ci shows 1 test failing, other than that, looks good

bjester commented 5 years ago

I have resolved the failing tests here, with explanation: https://github.com/pbs/pycaption/pull/186

bjester commented 5 years ago

I was able to upgrade beautifulsoup4 as well, with tests passing in both python versions, shown here in this commit. It's based off of py27-py3-compat so I would be happy to create a PR once this gets merged!

I was also able to refactor this code to not generate the HTML manually, but use bs4. It's a fairly substantial refactor, so I stuck with the most straightforward solution in the above commit.

virtosubogdan commented 5 years ago

Thanks @bjester ! Nice work