kkroening / ffmpeg-python

Python bindings for FFmpeg - with complex filtering support
Apache License 2.0
9.99k stars 886 forks source link

Typing annotation #723

Open Conchylicultor opened 1 year ago

Conchylicultor commented 1 year ago

Adding typing annotation to this project would allow VSCode and other editors to have auto-complete and auto-documentation on hover.

Currently there's auto-completion for ffmpeg., but not stream. after the first stream is returned. It would greatly improve usability and discoverability.

I'm not talking about typing annotation for arguments, but just return value def input(*args, **kwargs) -> Stream:, def trim(*args, **kwargs) -> Stream:,...

mattia-lecci commented 1 year ago

I'm also interested in this. Though, I wonder what the situation is regarding official releases. The last one in pypi is from July 2019. If there are plans to release more official releases, the community could come in help with typing annotations.

lucemia commented 8 months ago

I also encountered this problem, and ultimately, I decided to implement a typed version available at https://github.com/livingbio/typed-ffmpeg.

Poly2it commented 2 weeks ago

I also encountered this problem, and ultimately, I decided to implement a typed version available at https://github.com/livingbio/typed-ffmpeg.

This is possibly one of the finest comments on GitHub. The gracious, quite modest presentation at the bottom of this random unseen issue is so absurd and unbelievable considering the effort that must have gone into your reimplementation. Top effort, I am in awe.