Skip to content

Switch from pywin32 to ctype #5

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

Merged

Conversation

samepaul
Copy link
Contributor

@samepaul samepaul commented Apr 9, 2025

A bit less fancy looking code, but doesn't depend on pywin32 which is evil :)

@tikuma-lsuhsc
Copy link
Collaborator

@samepaul - thanks for the PR. I'll review it more in depth later, but I think you left out the most important change to exorcise the evil pywin32: it must be removed from pyproject.tml's dependencies. Could you do that, too?

@tikuma-lsuhsc
Copy link
Collaborator

Addresses Issue #4

Not sure, never dealt with delivering public Python modules
@tikuma-lsuhsc
Copy link
Collaborator

It's not passing the CI, failing both read & write tests with FFmpeg. If you could run FFmpeg on your system, please test with pytest.

@samepaul
Copy link
Contributor Author

samepaul commented Apr 9, 2025

It's not passing the CI, failing both read & write tests with FFmpeg. If you could run FFmpeg on your system, please test with pytest.

I'm unfortunately not really familiar with ffmpeg and what are expectations of it with regard to pipes. I notices that ERROR_BROKEN_PIPE should not generate exception and perhaps non-zero buffers affect behavior as well. I will commit that fix, but other than that is above me, sorry :(

@samepaul
Copy link
Contributor Author

samepaul commented Apr 9, 2025

It's not passing the CI, failing both read & write tests with FFmpeg. If you could run FFmpeg on your system, please test with pytest.

I would actually appreciate if you could review readinto because I am not entirely sure what exactly it is expected to do.

@tikuma-lsuhsc
Copy link
Collaborator

It's not passing the CI, failing both read & write tests with FFmpeg. If you could run FFmpeg on your system, please test with pytest.

I'm unfortunately not really familiar with ffmpeg and what are expectations of it with regard to pipes. I notices that ERROR_BROKEN_PIPE should not generate exception and perhaps non-zero buffers affect behavior as well. I will commit that fix, but other than that is above me, sorry :(

no biggie. I'll review and edit the code later when I find a chunk of time.

@tikuma-lsuhsc
Copy link
Collaborator

The test is passing on my PC, so it's good so far.

I would actually appreciate if you could review readinto because I am not entirely sure what exactly it is expected to do.

I think you're confused because the original version was overly cautious... My (unfounded) fear was that the read operation somehow times out and does not return the number of bytes requested without throwing an error. The ReadFile documentation does not suggest such possibility (I think) so we can stick to how you have it, and if a problem arises in the future I'll address it.

I'll let it sit for another day and will try merge it tomorrow night and publish the updated release.

@samepaul
Copy link
Contributor Author

The test is passing on my PC, so it's good so far.

I would actually appreciate if you could review readinto because I am not entirely sure what exactly it is expected to do.

I think you're confused because the original version was overly cautious... My (unfounded) fear was that the read operation somehow times out and does not return the number of bytes requested without throwing an error. The ReadFile documentation does not suggest such possibility (I think) so we can stick to how you have it, and if a problem arises in the future I'll address it.

I'll let it sit for another day and will try merge it tomorrow night and publish the updated release.

Sure. I’m glad you liked it. That was an interesting first time journey for me. 😊

@tikuma-lsuhsc tikuma-lsuhsc merged commit f5f0aeb into python-ffmpegio:master Apr 11, 2025
9 checks passed
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

Successfully merging this pull request may close these issues.

3 participants