docs
This commit is contained in:
parent
ad540f6005
commit
caf68380e8
3 changed files with 7 additions and 5 deletions
|
|
@ -194,8 +194,6 @@ match_filters
|
||||||
music_tags
|
music_tags
|
||||||
''''''''''
|
''''''''''
|
||||||
.. autoclass:: ytdl_sub.plugins.music_tags.MusicTagsOptions()
|
.. autoclass:: ytdl_sub.plugins.music_tags.MusicTagsOptions()
|
||||||
:members:
|
|
||||||
:exclude-members: partial_validate, embed_thumbnail
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
from typing import Any, Optional
|
|
||||||
from typing import Dict
|
from typing import Dict
|
||||||
from typing import List
|
from typing import List
|
||||||
|
from typing import Optional
|
||||||
|
|
||||||
import mediafile
|
import mediafile
|
||||||
|
|
||||||
|
|
@ -65,8 +65,10 @@ class MusicTagsOptions(OptionsDictValidator):
|
||||||
tags:
|
tags:
|
||||||
artist: "{artist}"
|
artist: "{artist}"
|
||||||
album: "{album}"
|
album: "{album}"
|
||||||
genre: "ytdl-sub"
|
|
||||||
# Supports id3v2.4 multi-tags
|
# Supports id3v2.4 multi-tags
|
||||||
|
genres:
|
||||||
|
- "{genre}"
|
||||||
|
- "ytdl-sub"
|
||||||
albumartists:
|
albumartists:
|
||||||
- "{artist}"
|
- "{artist}"
|
||||||
- "ytdl-sub"
|
- "ytdl-sub"
|
||||||
|
|
@ -93,7 +95,6 @@ class MusicTagsOptions(OptionsDictValidator):
|
||||||
self._is_old_format = True
|
self._is_old_format = True
|
||||||
self._tags = tags_validator or MusicTagsValidator(name=name, value={})
|
self._tags = tags_validator or MusicTagsValidator(name=name, value={})
|
||||||
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def tags(self) -> MusicTagsValidator:
|
def tags(self) -> MusicTagsValidator:
|
||||||
"""
|
"""
|
||||||
|
|
@ -126,6 +127,7 @@ class MusicTagsPlugin(Plugin[MusicTagsOptions]):
|
||||||
f"to audio using the audio_extract plugin."
|
f"to audio using the audio_extract plugin."
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# pylint: disable=protected-access
|
||||||
if self.plugin_options._is_old_format:
|
if self.plugin_options._is_old_format:
|
||||||
logger.warning(
|
logger.warning(
|
||||||
"music_tags.tags is now deprecated. Place your tags directly under music_tags "
|
"music_tags.tags is now deprecated. Place your tags directly under music_tags "
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,7 @@ def single_song_preset_dict_old_format(output_directory):
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
def single_song_preset_dict(output_directory):
|
def single_song_preset_dict(output_directory):
|
||||||
return {
|
return {
|
||||||
|
|
@ -43,6 +44,7 @@ def single_song_preset_dict(output_directory):
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
def multiple_songs_preset_dict(output_directory):
|
def multiple_songs_preset_dict(output_directory):
|
||||||
return {
|
return {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue