aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpukkandan <pukkandan.ytdlp@gmail.com>2022-08-31 22:49:14 +0530
committerpukkandan <pukkandan.ytdlp@gmail.com>2022-09-01 16:46:31 +0530
commitf2e9fa3ef7a7ce8e18cec53ea7956a3bb36c59ea (patch)
tree7cd85cd665988b0bacea3bc3b50abf23329cd7c4
parent50a399326fa82e2e5fe3f2829da5a31407adafaa (diff)
downloadhypervideo-pre-f2e9fa3ef7a7ce8e18cec53ea7956a3bb36c59ea.tar.lz
hypervideo-pre-f2e9fa3ef7a7ce8e18cec53ea7956a3bb36c59ea.tar.xz
hypervideo-pre-f2e9fa3ef7a7ce8e18cec53ea7956a3bb36c59ea.zip
[FormatSort] Fix `aext` for `--prefer-free-formats`
Closes #4735
-rw-r--r--README.md2
-rw-r--r--yt_dlp/extractor/common.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/README.md b/README.md
index 83ab309c6..176832ca9 100644
--- a/README.md
+++ b/README.md
@@ -1530,7 +1530,7 @@ The available fields are:
- `acodec`: Audio Codec (`flac`/`alac` > `wav`/`aiff` > `opus` > `vorbis` > `aac` > `mp4a` > `mp3` > `eac3` > `ac3` > `dts` > other)
- `codec`: Equivalent to `vcodec,acodec`
- `vext`: Video Extension (`mp4` > `webm` > `flv` > other). If `--prefer-free-formats` is used, `webm` is preferred.
- - `aext`: Audio Extension (`m4a` > `aac` > `mp3` > `ogg` > `opus` > `webm` > other). If `--prefer-free-formats` is used, the order changes to `opus` > `ogg` > `webm` > `m4a` > `mp3` > `aac`.
+ - `aext`: Audio Extension (`m4a` > `aac` > `mp3` > `ogg` > `opus` > `webm` > other). If `--prefer-free-formats` is used, the order changes to `ogg` > `opus` > `webm` > `mp3` > `m4a` > `aac`
- `ext`: Equivalent to `vext,aext`
- `filesize`: Exact filesize, if known in advance
- `fs_approx`: Approximate filesize calculated from the manifests
diff --git a/yt_dlp/extractor/common.py b/yt_dlp/extractor/common.py
index b79221955..b9d0305b4 100644
--- a/yt_dlp/extractor/common.py
+++ b/yt_dlp/extractor/common.py
@@ -1693,7 +1693,7 @@ class InfoExtractor:
'order_free': ('webm', 'mp4', 'flv', '', 'none')},
'aext': {'type': 'ordered', 'field': 'audio_ext',
'order': ('m4a', 'aac', 'mp3', 'ogg', 'opus', 'webm', '', 'none'),
- 'order_free': ('opus', 'ogg', 'webm', 'm4a', 'mp3', 'aac', '', 'none')},
+ 'order_free': ('ogg', 'opus', 'webm', 'mp3', 'm4a', 'aac', '', 'none')},
'hidden': {'visible': False, 'forced': True, 'type': 'extractor', 'max': -1000},
'aud_or_vid': {'visible': False, 'forced': True, 'type': 'multiple',
'field': ('vcodec', 'acodec'),