Skip to content

Conversation

@aboood40091
Copy link
Contributor

Add support for locating FFmpeg DLLs on Windows.

Fixes #1108, #1014, and several other issues.

Add support for locating FFmpeg DLLs on Windows.
@meta-cla
Copy link

meta-cla bot commented Dec 9, 2025

Hi @aboood40091!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at [email protected]. Thanks!

@meta-cla
Copy link

meta-cla bot commented Dec 9, 2025

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks!

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Dec 9, 2025
Copy link
Contributor

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @aboood40091

I'm happy to try that out if CI is green. It's very hard to debug Windows issues for us because we don't have easy access to Windows machines, so I do appreciate the help on this.

What I do not understand though: why are users experiencing these issues, when our Windows CI jobs are just fine? There must be a fundamental env difference that I'm currently missing?

Comment on lines 77 to 78
versions 4, 5, 6, 7, and 8. On Windows, ensure you've installed
the "full-shared" version.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did a quick search and I wasn't able to find an authoritative source on what a full-shared version is. I assume it's an version that ships dll instead of statically linking all libraries.

My concern is that this error message may not be directly actionable for users, unless we add more details on how they can install such a "full-shared" version. These details aren't really in scope here, so maybe we can leave this error message as it was?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct. "full-shared" is the version that ships DLLs instead of statically linking them. "full-shared" is the term used in the download page.

Screenshot_20251209-145038_Brave
Screenshot_20251209-145314_Brave

Personally, I did not know the shared version is the one that has all DLLs until I started digging enough, so I figured this information would be helpful.

If you still would like me to reverse the change to the message, please let me know.

@aboood40091
Copy link
Contributor Author

Thanks @aboood40091

...

What I do not understand though: why are users experiencing these issues, when our Windows CI jobs are just fine? There must be a fundamental env difference that I'm currently missing?

Personally, I don't know. It actually should not work for you under normal circumstances according to the Python documentation due to a breaking change in Python 3.8. Refer to:
https://docs.python.org/3/whatsnew/3.8.html#bpo-36085-whatsnew

The use of add_dll_directory is required now as PATH will no longer be searched for DLLs. Perhaps whatever environment you have somehow overrides this, or it's already called add_dll_directory somewhere behind the scenes.

Copy link
Contributor

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @aboood40091 . CI is failing with an unrelated issue which is also visible in #1111. I'll try to fix that first, then hopefully this PR will be green and I'll merge it.

Copy link
Contributor

@Dan-Flores Dan-Flores left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The two error signals are known and being tracked in #1047, lets merge this PR. Thanks!

@Dan-Flores Dan-Flores merged commit a2f1e4e into meta-pytorch:main Dec 9, 2025
66 of 68 checks passed
Dan-Flores pushed a commit that referenced this pull request Dec 9, 2025
Dan-Flores pushed a commit that referenced this pull request Dec 9, 2025
Dan-Flores added a commit that referenced this pull request Dec 9, 2025
@aboood40091
Copy link
Contributor Author

@NicolasHug in your latest changes, cm is undefined if ffmpeg path is null. Is this intentional?

@NicolasHug
Copy link
Contributor

😮 thanks for catching this @aboood40091 . Let me submit a follow-up. We're planning to publish a bugfix release later today with your windows fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cannot find FFmpeg DLLs by default

3 participants