Merge pull request #258 from exislow/file-extension-fix

File extension fix
This commit is contained in:
exislow
2024-11-29 18:04:15 +01:00
committed by GitHub
2 changed files with 2 additions and 9 deletions
+1
View File
@@ -16,6 +16,7 @@ classifiers = [
"Programming Language :: Python :: 3", "Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
] ]
[tool.poetry.scripts] [tool.poetry.scripts]
+1 -9
View File
@@ -341,15 +341,7 @@ class Download:
return False, "" return False, ""
if isinstance(media, Track): if isinstance(media, Track):
# TODO: HOTFIX! Go back to file_extension = media_stream.get_stream_manifest().file_extension
# file_extension = media_stream.get_stream_manifest().file_extension
# After tidalapi has fixed #304
if stream_manifest.file_extension is VideoExtensions.TS:
file_extension = stream_manifest.file_extension
elif stream_manifest.dash_info and AudioExtensions.FLAC in stream_manifest.dash_info.first_url:
file_extension = AudioExtensions.FLAC
else:
file_extension = AudioExtensions.M4A
if self.settings.data.extract_flac and ( if self.settings.data.extract_flac and (
stream_manifest.codecs.upper() == Codec.FLAC and file_extension != AudioExtensions.FLAC stream_manifest.codecs.upper() == Codec.FLAC and file_extension != AudioExtensions.FLAC