Commit Graph

250 Commits

Author SHA1 Message Date
std-move af7a5eef2f
[downloader/aria2c] Fix filename containing leading whitespace (#5099)
Similar to eb55bad5a0, but for fragmented downloads
Authored by: std-move
2022-10-01 21:00:14 +05:30
nixxo 81b6102d20
[downloader/ism] Support ec-3 codec (#5004)
Closes #296
Authored by: nixxo
2022-09-30 23:03:29 +05:30
pukkandan deae7c1711
[cleanup] Misc 2022-09-10 03:46:54 +05:30
pukkandan da4db748fa
[utils] Add `deprecation_warning`
See https://github.com/yt-dlp/yt-dlp/pull/2173#issuecomment-1097021515
2022-08-30 21:03:07 +05:30
pukkandan e1eabd7beb
[downloader/external] Smarter detection of executable
Closes #4778
2022-08-30 18:13:38 +05:30
Lesmiscore 62b58c0936
[docs] Consistent use of `e.g.` (#4643)
Authored by: Lesmiscore
2022-08-14 17:34:13 +05:30
pukkandan be5c1ae862
Standardize retry mechanism (#1649)
* [utils] Create `RetryManager`
* Migrate all retries to use the manager
* [extractor] Add wrapper methods for convenience
* Standardize console messages for retries
* Add `--retry-sleep` for extractors
2022-08-02 01:43:18 +05:30
pukkandan 3df4f81dfe
[downloader] Add average speed to final progress line
Fixes: https://github.com/ytdl-org/youtube-dl/issues/31122
2022-07-31 04:20:02 +05:30
pukkandan b4daacb4ec
[mhtml, cleanup] Use imghdr 2022-07-31 02:20:12 +05:30
pukkandan 6929b41a21
Remove Python 3.6 support
Closes #3764
2022-07-18 06:31:14 +05:30
pukkandan f5ea47488a
[cleanup] Minor fixes 2022-07-11 02:24:36 +05:30
pukkandan 6d645b5577
[http] Ensure the file handle is always closed
Closes #4323
2022-07-11 01:13:29 +05:30
pukkandan ae61d108dd
[cleanup] Misc cleanup 2022-06-29 06:43:27 +05:30
pukkandan bbae437723
[hls] Warn user when trying to download live HLS
We do not automatically switch to ffmpeg because the detection is not 100% accurate
2022-06-26 04:48:41 +05:30
pukkandan 14f25df2b6
[compat] Remove deprecated functions from core code 2022-06-25 00:14:12 +05:30
pukkandan 54007a45f1
[cleanup] Consistent style for file heads 2022-06-25 00:08:58 +05:30
pukkandan ac66811112
[compat] Remove more functions
Removing any more will require changes to a large number of extractors
2022-06-25 00:08:55 +05:30
pukkandan 998a3cae0c
[cleanup] Misc fixes 2022-06-22 03:47:41 +05:30
pukkandan 95032f302c
[f4m] Bugfix 2022-06-21 13:03:29 +05:30
pukkandan f0c9fb9682
[utils] `Popen`: Refactor to use contextmanager
Fixes https://github.com/yt-dlp/yt-dlp/issues/3531#issuecomment-1156223597
2022-06-16 06:23:50 +05:30
pukkandan 64fa820ccf
[cleanup] Misc fixes (see desc)
* [tvver] Fix bug in 6837633a4a - Closes #4054
* [rumble] Fix tests - Closes #3976
* [make] Remove `cat` abuse - Closes #3989
* [make] Revert #3684 - Closes #3814
* [utils] Improve `get_elements_by_class` - Closes #3993
* [utils] Inherit `Namespace` from `types.SimpleNamespace`
* [utils] Use `re.fullmatch` for matching filters
* [jsinterp] Handle quotes in `_separate`
* [make_readme] Allow overshooting last line

Authored by: pukkandan, kwconder, MrRawes, Lesmiscore
2022-06-12 00:08:16 +05:30
MMM 36195c4461
[dash] Show fragment count with `--live-from-start` (#3493)
Authored by: flashdagger
2022-06-07 05:44:08 -07:00
pukkandan 5ec1b6b716
Add option `--download-sections` to download video partially
Closes #52, Closes #3932
2022-06-07 02:41:55 +05:30
pukkandan 1890fc6389
[cleanup] Misc fixes
Cherry-picks from: #3498, #3947
Related: #3949, https://github.com/yt-dlp/yt-dlp/issues/1839#issuecomment-1140313836
Authored by: pukkandan, flashdagger, gamer191
2022-06-03 21:45:35 +05:30
pukkandan 8a7f6d7a15
Do not print progress to `stderr` with `-q`
It is arguable how this "should" behave, but since progress is always
written to stdout in older yt-dl/p, we should keep it as-is

Bug in cf4f42cb97
Closes #3844
2022-06-01 01:57:14 +05:30
pukkandan 8a82af3511
[cleanup] Misc fixes and cleanup
Closes #3780, Closes #3853, Closes #3850
2022-05-27 04:43:43 +05:30
pukkandan 11233f2afd
[downloader, cleanup] Refactor `report_progress`
Closes #3790
2022-05-22 21:54:06 +05:30
pukkandan c487cf0010
[cleanup] Misc 2022-05-21 16:01:53 +05:30
pukkandan 1a8cc83735
Bugfix for 3a408f9d19 2022-05-20 21:25:07 +05:30
pukkandan 2762dbb17e
[compat] Add `functools.cached_property` 2022-05-20 21:06:37 +05:30
pukkandan 666c36d58d
Bugfix for 23326151c4 2022-05-20 21:03:19 +05:30
pukkandan 23326151c4
Add option --retry-sleep (#3059)
Closes #2852
2022-05-19 20:00:31 +05:30
pukkandan 7896214c42
Bugfix for 591bb9d355
Closes #3769
2022-05-17 22:33:15 +05:30
pukkandan 591bb9d355
Fix color in `-q -F`
and convert `ydl._out_files`/`ydl._allow_colors` to `Namespace`

Closes #3761
2022-05-17 18:41:46 +05:30
coletdjnz 5faf6528fb
[http] Fix bug in retrying on read timeout in py < 3.10
socket.timeout is not an alias of TimeoutError in py < 3.10
Fixes bug in a2e77303e3
Authored-by: coletdjnz
2022-05-17 09:17:37 +12:00
pukkandan 3a408f9d19
Show name of downloader in verbose log
Closes #3703
2022-05-11 07:20:54 +05:30
pukkandan 0f06bcd759
[cleanup] Minor fixes (See desc)
* [youtube] Fix `--youtube-skip-dash-manifest`
* [build] Use `$()` in `Makefile`. Closes #3684
* Fix bug in 385ffb467b
* Fix bug in 43d7f5a5d0
* [cleanup] Remove unnecessary `utf-8` from `str.encode`/`bytes.decode`
* [utils] LazyList: Expose unnecessarily "protected" attributes
and other minor cleanup
2022-05-09 17:59:26 +05:30
felix e4fa34a13e
[hls] Fix unapplied byte_range for EXT-X-MAP fragment
Cherry-picked from #3302
Authored by: fstirlitz
2022-05-02 07:20:08 +05:30
pukkandan 3fe75fdc80
[cleanup] Misc fixes (see desc)
* Do not warn when fixup is skipped for existing file
* [fragment] Fix `--skip-unavailable-fragments` for HTTP Errors
* [utils] write_string: Fix bug in 59f943cd50
* [utils] parse_codecs: Subtitle codec is generally referred to as `scodec`. https://github.com/yt-dlp/yt-dlp/pull/2174#discussion_r790156048
* [docs] Remove note about permissions. Closes #3597
2022-05-01 04:58:38 +05:30
pukkandan 1d485a1a79
[cleanup] Misc fixes
Closes #3565, https://github.com/yt-dlp/yt-dlp/issues/3514#issuecomment-1105944364
2022-04-29 07:39:33 +05:30
pukkandan 0a5a191a2a
Improve `--clean-infojson`
It should not removes fields that may be needed for `--load-infojson`.
Eg: `_ffmpeg_args`, `_has_drm`
2022-04-28 20:04:40 +05:30
Elyse 00828e2c93
[downloader/ffmpeg] Specify headers for each URL (#3553)
Closes #2696
Authored by: elyse0
2022-04-26 02:54:56 -07:00
Lesmiscore 69b59b4b4b
[downloader/fc2] Stop heatbeating once FFmpeg finishes
Authored by: Lesmiscore
2022-04-25 00:45:25 +09:00
pukkandan 9b8ee23b99
[dependencies] Create module with all dependency imports 2022-04-21 00:48:52 +05:30
pukkandan 43cc91ad75
bugfix for 19a0394044, 3d3bb1688b 2022-04-18 05:41:56 +05:30
felix 77f9033095
[compat] Split into sub-modules (#2173)
Authored by: fstirlitz, pukkandan
2022-04-18 04:26:43 +05:30
pukkandan 19a0394044
[cleanup] Misc cleanup and refactor (#2173) 2022-04-18 02:28:28 +05:30
Lesmiscore (Naoya Ozaki) c854208ccf
[downloader/fragment] Make single thread download work for --live-from-start (#3446)
Authored by: Lesmiscore
2022-04-16 21:11:09 +09:00
pukkandan e06bd8800f
Fix `--skip-unavailable-fragments`
Bug in d71fd41249
Closes #3437
2022-04-15 23:47:37 +05:30
pukkandan 3b9d9f4374
Do not change fragment chunk-size when `--test`
Closes #3434
2022-04-15 17:05:56 +05:30
pukkandan f82711587c
[cleanup] Sort imports
Using https://github.com/PyCQA/isort

    isort -m VERTICAL_HANGING_INDENT --py 36 -l 80 --rr -n --tc .
2022-04-12 05:32:52 +05:30
pukkandan 86e5f3ed2e
[cleanup] Upgrade syntax
Using https://github.com/asottile/pyupgrade

1. `__future__` imports and `coding: utf-8` were removed
2. Files were rewritten with `pyupgrade --py36-plus --keep-percent-format`
3. f-strings were cherry-picked from `pyupgrade --py36-plus`

Extractors are left untouched (except removing header) to avoid unnecessary merge conflicts
2022-04-12 05:32:51 +05:30
pukkandan f9934b9614
[cleanup] Mark some compat variables for removal (#2173)
Authored by fstirlitz, pukkandan
2022-04-12 05:32:50 +05:30
pukkandan 0edb3e336c
Do not prevent download if locking is unsupported
Closes #3022

Failure to lock download-archive is still fatal.
This is consistent with youtube-dl's behavior
2022-04-05 23:32:22 +05:30
pukkandan ce0593ef61
[http] Fix #3215 2022-04-05 21:31:59 +05:30
pukkandan a44ca5a470
[cleanup] Misc fixes
Closes https://github.com/yt-dlp/yt-dlp/pull/3213, Closes https://github.com/yt-dlp/yt-dlp/pull/3117

Related: https://github.com/yt-dlp/yt-dlp/issues/3146#issuecomment-1077323114, https://github.com/yt-dlp/yt-dlp/pull/3277#discussion_r841019671, a825ffbffa (commitcomment-68538986), https://github.com/yt-dlp/yt-dlp/issues/2360, 5fa3c9a88f (r70393519), 5fa3c9a88f (r70393254)
2022-04-05 18:12:18 +05:30
pukkandan c4f60dd7cd
[utils] Add `try_call` 2022-03-31 13:33:27 +05:30
pukkandan 28787f16c6
[downloader] Fix invocation of `HttpieFD`
Closes #3154
2022-03-25 13:00:42 +05:30
coletdev af14914baa
Remove `Accept-Encoding` header from `std_headers` (#3153)
This should be set by each downloader to what it supports.
Fixes https://github.com/yt-dlp/yt-dlp/issues/3142
Authored-by: coletdjnz
2022-03-23 07:47:02 +00:00
coletdev 8a23db9519
[wget] Fix proxy (#3152)
Upstream PR: https://github.com/ytdl-org/youtube-dl/pull/29343
Authored-by: kikuyan, coletdjnz
2022-03-22 14:24:27 -07:00
Lesmiscore (Naoya Ozaki) be4685ab7b
[http] Reject broken range before request (#3079)
* And fix filesize estimate for byterange downloads

Closes #2001
Authored by: Lesmiscore, Jules-A, pukkandan
2022-03-18 18:15:01 -07:00
coletdev a2e77303e3
[downloader/http] Retry on more errors (#3065)
Closes #3056, #2071
Related: #3034, #2969
Authored-by: coletdjnz
2022-03-18 22:10:20 +00:00
Lesmiscore (Naoya Ozaki) d71fd41249
[fragment] Read downloaded fragments only when needed (#3069)
Authored by: Lesmiscore
2022-03-15 12:27:41 +09:00
coletdev b3edc8068e
[downloader/mhtml] Fix fragments with absolute urls (#3044)
Authored-by: coletdjnz
2022-03-13 22:03:40 +00:00
pukkandan 592b748582
[cleanup] Minor cleanup
Closes #3006
2022-03-11 19:40:15 +05:30
pukkandan cf4f42cb97
Protect stdout from unexpected progress and console-title
Closes #3023
2022-03-11 19:29:45 +05:30
pukkandan 08d30158ec
[cleanup, docs] Misc cleanup
Closes #2828, closes #2734, closes #2802, closes #2937
2022-03-08 22:38:06 +05:30
Emanuel Hoogeveen 45806d44a7
[downloader] Obey `--file-access-retries` when deleting/renaming (#2224)
Authored by: ehoogeveen-medweb
2022-03-03 06:33:32 -08:00
Lesmiscore (Naoya Ozaki) 93c8410d33
[downloader/fragment] Fix bugs around resuming with Range (#2901)
Authored by: Lesmiscore
2022-02-28 13:10:54 +09:00
Lesmiscore 195c22840c
[downloader/fragment] Ignore `FileNotFoundError` when downloading livestreams
when `--live-from-start` is used for YouTube and the live ends, request for the last segment prematurely ends (or 404, 403).
this is causing lack of the file and `FileNotFoundError`
lacking segment doesn't have any data, so it's safe to ignore
2022-02-26 12:34:36 +09:00
Lesmiscore f0734e1190
[downloader/fragment] Fix problem where multiple threads can share one iterator
which causes "ValueError: generator already executing" error

Closes #2881
2022-02-25 13:22:17 +09:00
Lesmiscore (Naoya Ozaki) 15dfb3929c
[fc2:live] Add extractor (#2418)
Authored by: Lesmiscore
2022-02-25 11:16:23 +09:00
Lesmiscore (Naoya Ozaki) a539f06570
[downloader/fragment] Improve `--live-from-start` for YouTube livestreams (#2870) 2022-02-25 02:00:46 +09:00
pukkandan dcd55f766d
[aria2c] Add `--http-accept-gzip=true`
Closes #1936, #1236
2022-02-18 18:03:20 +05:30
pukkandan 079a7cfc71
[downloader] Do not use aria2c for non-native `m3u8`
Closes #2718
2022-02-11 12:09:03 +05:30
pukkandan 1e5d87beee
[websocket] Make syntax error in `websockets` module non-fatal
Closes #2633
2022-02-04 12:02:01 +05:30
pukkandan 1d3586d0d5
[aes] Add unpad_pkcs7 2022-02-01 00:29:36 +05:30
pukkandan af6793f804
[downloader/ffmpeg] Handle unknown formats better 2022-01-24 01:15:54 +05:30
pukkandan d57576b9d9
[httpie] Fix `available` method
Closes #2330
2022-01-13 22:20:59 +05:30
pukkandan f44afb54ef
[aria2c] Don't show progress when `--no-progress` 2021-12-27 04:27:34 +05:30
pukkandan 185bf31070
[youtube] End `live-from-start` properly when stream ends with 403
Closes #2089
2021-12-26 16:14:00 +05:30
Emanuel Hoogeveen 205a0654c0
Add option `--file-access-retries` (#2066)
Closes #517
Authored by: ehoogeveen-medweb
2021-12-23 07:59:03 +05:30
pukkandan b69fd25c25
[cleanup] Misc cleanup
Closes #1942 #1976 #2020 #2058 #1984
2021-12-23 07:12:46 +05:30
pukkandan 4ac5b94807
[dash] Fix `--test`
Bug in adbc4ec4bb
2021-12-23 03:34:18 +05:30
pukkandan 4273cc776d
[dash] Fix aria2c dash downloads
Bug in adbc4ec4bb
2021-12-21 21:40:04 +05:30
The Hatsune Daishi adbc4ec4bb
[dash,youtube] Download live from start to end (#888)
* Add option `--live-from-start` to enable downloading live videos from start
* Add key `is_from_start` in formats to identify formats (of live videos) that downloads from start
* [dash] Create protocol `http_dash_segments_generator` that allows a function to be passed instead of fragments
* [fragment] Allow multiple live dash formats to download simultaneously
* [youtube] Implement fragment re-fetching for the live dash formats
* [youtube] Re-extract dash manifest every 5 hours (manifest expires in 6hrs)
* [postprocessor/ffmpeg] Add `FFmpegFixupDuplicateMoovPP` to fixup duplicated moov atoms

Known issue: Ctrl+C doesn't work on Windows when downloading multiple formats

Closes #1521
Authored by: nao20010128nao, pukkandan
2021-12-20 11:36:46 +05:30
pukkandan f304da8a29
[cleanup] Misc cleanup
Closes #1805, closes #1800
2021-11-29 23:34:33 +05:30
pukkandan 7578d77d8c
[downloader] Add colors to download progress 2021-11-29 22:51:18 +05:30
pukkandan 234416e4bf
[downloader/ffmpeg] Fix for direct videos inside mpd manifests
Closes #1751
2021-11-23 01:29:10 +05:30
pukkandan d76991ab07
Fix `--check-formats` for `mhtml`
Closes #1709
2021-11-20 08:33:55 +05:30
nyuszika7h 6b993ca765
[hls] Better FairPlay DRM detection (#1661)
Authored by: nyuszika7h
2021-11-19 07:19:51 +05:30
pukkandan 59a7a13ef9
[docs] Minor documentation improvements
Closes #1583, #1599
2021-11-10 04:19:52 +05:30
pukkandan a4211baff5
[cleanup] Minor cleanup 2021-11-04 03:53:15 +05:30
pukkandan 8913ef74d7
[ffmpeg] Detect libavformat version for `aac_adtstoasc`
and print available features in verbose head
Based on https://github.com/ytdl-org/youtube-dl/pull/29581
2021-11-04 03:13:37 +05:30
pukkandan bd93fd5d45
[fragment] Fix progress display in fragmented downloads
Closes #1517
2021-11-03 16:45:58 +05:30
pukkandan 49a57e70a9
[cleanup] misc 2021-10-23 02:09:10 +05:30
pukkandan d3c93ec2b7
Don't create console for subprocesses on Windows (#1261)
Closes #1251
2021-10-20 21:49:40 +05:30
pukkandan b4b855ebc7
[fragment] Print error message when skipping fragment 2021-10-19 22:58:26 +05:30
pukkandan 2cda6b401d
Revert "[fragments] Pad fragments before decrypting (#1298)"
This reverts commit 373475f035.
2021-10-19 22:58:25 +05:30
pukkandan aa7785f860
[utils] Standardize timestamp formatting code
Closes #1285
2021-10-19 22:58:25 +05:30