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
yt-dlp: Add mutagen variant #20465
yt-dlp: Add mutagen variant #20465
Conversation
Notifying maintainers: |
All you've done here is add a dependency. You haven't told yt-dlp that it should use AtomicParsley or py-mutagen. |
Also, you haven't removed the AtomicParsley dependency when the mutagen variant is used. |
yt-dlp automatically prioritizes mutagen and AtomicParsley, depending on which one is found first. Simply adding the dependency is sufficient.
I can't remove it even when removing it with |
Yes, I'm sure that is what will happen but it is not sufficient for MacPorts. Consider the opposite situation: The user does not select the mutagen variant, but the user happens to have mutagen installed. The user expects yt-dlp to use AtomicParsley, but it uses mutagen, despite not declaring a dependency on it. We don't want that to happen.
I understand that simply adding Yes, when there are two conflicting options, like AtomicParsley and mutagen, having two separate variants, which are marked as conflicting with one another and where the port enforces that one of the two variants must be selected and one of them is selected by default, is optimal in my opinion. It is complicated by the fact that yt-dlp is a subport of youtube-dl and youtube-dl presumably does not have the option of using mutagen. What is the relationship between ffmpeg and AtomicParsley and mutagen? Currently the ffmpeg variant depends on both ffmpeg and AtomicParsley. Was that the right thing to do? Is the answer the same for youtube-dl and yt-dlp? Can ffmpeg be used without AtomicParsley? Can AtomicParsley be used without ffmpeg? Does mutagen use ffmpeg—mandatorily, optionally, or not at all? The answers to these questions might tell us whether we should have three variants, one for adding each dependency (and whatever mechanism might be needed to inform the software that it should or should not use that dependency), and which of them should The reason the ticket has remained unsolved for so many months is my lack of motivation to research the answers to these questions. |
The hierarchy of dependencies which are of concern in this PR (AtomicParsley, mutagen, ffmpeg) is the following:
This can also be said about youtube-dl, although without mutagen in the mix. Given the concerns previously raised, I don't think this can be resolved. Even if both youtube-dl and yt-dlp were to be separate port files, neither project has some kind of configuration system when building, making it impossible for either project to prioritize a dependency over another. As it stands, both projects have logic to detect and fallback on dependencies it's missing, but there's no way to enforce one dependency over another without heavy patching. |
Description
Add mutagen variant to yt-dlp subport. This allows for mutagen to be used over AtomicParsley for metadata manipulation (e.g thumbnail embedding)
Closes: https://trac.macports.org/ticket/66945
Type(s)
Tested on
macOS 12.6 21G115 arm64
Xcode 14.2 14C18
Verification
Have you
port lint --nitpick
?sudo port test
?sudo port -vst install
?