Commit Graph

230 Commits (0fe51254cb878cf5f65801e2b62424a185665639)

Author SHA1 Message Date
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)
Lesmiscore (Naoya Ozaki) 5d45484cc7
[niconico] Fix extraction of thumbnails and uploader ()
pukkandan e6f868a63c
[utils] `traverse_obj`: Allow filtering by value
pukkandan c4f60dd7cd
[utils] Add `try_call`
pukkandan 8a7f68d0b1
[ffmpeg] Cache version data
Related: https://github.com/dasl-/pifi/issues/9
pukkandan 90137ca4be
[utils] Add `filter_dict`
coletdev 1c1b2f96ae
[youtube:tab] Fix duration extraction for shorts ()
Related: https://github.com/TeamNewPipe/NewPipe/issues/8034
Authored-by: coletdjnz
pukkandan 5c3895fff1
[outtmpl] Limit changes during sanitization
Closes 
pukkandan 6db9c4d57d
Ignore format-specific fields in initial pass of `--match-filter`
Closes 
Lesmiscore (Naoya Ozaki) 3cea3edd1a
[utils] WebSocketsWrapper: Allow omitting `__enter__` invocation ()
Authored by: Lesmiscore
pukkandan b1a7cd056a
Treat multiple `--match-filters` as OR
Closes 
pukkandan 28787f16c6
[downloader] Fix invocation of `HttpieFD`
Closes 
coletdev af14914baa
Remove `Accept-Encoding` header from `std_headers` ()
This should be set by each downloader to what it supports.
Fixes https://github.com/yt-dlp/yt-dlp/issues/3142
Authored-by: coletdjnz
coletdev d5820461e8
Use certificates from `certifi` if installed ()
Fixes  and most `CERTIFICATE_VERIFY_FAILED` issues

Authored by: coletdjnz
s0u1h eeb2a770f3
[utils] `format_decimal_suffix`: Fix for very large numbers ()
Authored by: s0u1h
pukkandan 592b748582
[cleanup] Minor cleanup
Closes 
pukkandan 76aa991374
Fix case of `http_headers`
Bug in 8b7539d27c

Fixes https://github.com/yt-dlp/yt-dlp/issues/1346#issuecomment-1064527765
pukkandan e491d06d34
[utils] ExtractorError: Fix for older python versions
Closes 
pukkandan ff91cf7483
[utils] Add `get_first`
pukkandan d1b5f70bc9
[cleanup] Refactor `__init__.py` ()
* Split `__init__` code into multiple functions
* Clean up validation code by grouping similar types of options
* Expose `parse_options` to third parties
pukkandan 08d30158ec
[cleanup, docs] Misc cleanup
Closes , closes , closes , closes 
coletdev 4390d5ec12
Add brotli content-encoding support ()
Authored by: coletdjnz
pukkandan 497d2fab6c
[utils] Better traceback for `ExtractorError`
Lesmiscore 1ed7953a74
[utils] render_table: Fix character calculation for removing extra gap
without this fix, the column next to delimiter will lack leading spaces on terminal (see https://github.com/yt-dlp/yt-dlp/pull/920#issuecomment-1059914615 for the situation)
Zenon Mousmoulas 27231526ae
[ant1newsgr] Add extractor ()
Authored by: zmousm
pukkandan 8b7539d27c
Implement `--add-header` without modifying `std_headers`
Closes , 
pukkandan 4c3f8c3fb6
Handle negative duration from extractor
Closes 
pukkandan 7265a2190c
Fix doubling of `video_id` in `ExtractorError`
pukkandan 747c0bd127
[utils] Improve file locking
* Implement non-blocking locks for windows
* Don't raise error when closing a closed file
Justin Keogh acea8d7cfb
[utils] Fix file locking for AOSP ()
Closes , 

Authored by: jakeogh
pukkandan f1d130902b
[utils] OnDemandPagedList: Do not download pages after error
Lesmiscore (Naoya Ozaki) 93c8410d33
[downloader/fragment] Fix bugs around resuming with Range ()
Authored by: Lesmiscore
Lesmiscore (Naoya Ozaki) 15dfb3929c
[fc2:live] Add extractor ()
Authored by: Lesmiscore
Lesmiscore (Naoya Ozaki) 3e9b66d761
[AbemaTV] Add extractors ()
Authored by: Lesmiscore
pukkandan 09b49e1f68
Add pre-processor stage `after_filter`
* Move `_match_entry` and `post_extract` to `process_video_result`. It is also left in `process_info` for API compat
* `--list-...` options and `--force-write-archive` now obey filtering options
* Move `SponsorBlockPP` to `after_filter`. Closes https://github.com/yt-dlp/yt-dlp/issues/2536
* Reverts 4ec82a72bb since this commit addresses the issue it was solving
Bepis febff4c119
[tubitv] Fix/improve TV series extraction ()
Authored by: bbepis
Lesmiscore (Naoya Ozaki) da42679b87
[utils] WebSockets wrapper for non-async functions ()
Authored by: Lesmiscore
pukkandan d49f8db39f
[utils] Validate `DateRange` input
Closes 
Justin Keogh a3125791c7
[utils] Use `locked_file` for `sanitize_open` ()
Authored by: jakeogh
pukkandan 455a15e2dc
[cleanup,docs] Minor fixes
Closes , 
pukkandan 4918522735
[utils] Strip double spaces in `clean_html`
Closes 
Authored by: dirkf
pukkandan 65662dffb1
Make nested --config-locations relative to parent file
* and allow environment variables in it so that you can use `$PWD`/`%cd%`
to specify paths relative to current directory
pukkandan d16df59db5
Fix `--compat-options list-formats`
Closes 
pukkandan d37707bda4
Fix/improve `InAdvancePagedList`
pukkandan e0ddbd02bd
[cleanup] Use format_field where applicable
xtkoba f81c62a6a4
Add option --legacy-server-connect ()
to allow HTTPS connection to servers that do not support RFC 5746 secure renegotiation

Authored by: xtkoba
pukkandan b1156c1e59
Fix d14cbdd92d
coletdjnz 396a76f7bf
[youtube] Enforce UTC ()
and [utils] use `utcnow` in `datetime_from_str`

Related:  
Authored by: coletdjnz
pukkandan d14cbdd92d
[utils] Add `Sec-Fetch-Mode` to `std_headers`
Closes 
pukkandan 19b4c74d40
Revert d6579d532b
Closes , Reopens 
pukkandan 8bd1c00bf3
[utils] Handle `ss:xxx` in `parse_duration`
Closes 
pukkandan 3b603dbdf1
Add option `--concat-playlist`
Closes , related: 
pukkandan d6579d532b
[utils] Partially revert d76d15a669
Closes 
Zenon Mousmoulas 0254f16274
[utils] Improve `get_elements_text_and_html_by_attribute` regex ()
Authored by: zmousm, pukkandan
Zenon Mousmoulas 6f32a0b5b7
[utils] Improve parsing for nested HTML elements ()
and add functions to return the HTML of elements

Authored by: zmousm
pukkandan 9e907ebddf
[cleanup] Misc cleanup
pukkandan 06e57990f7
Allow multiple and nested configuration files
pukkandan ebed8b3732
Add more post-processing stages
playlist = After entire playlist
after_video = After downloading all formats of a video
pukkandan 1e43a6f733
Allow `--exec` to be run at any post-processing stage
Deprecates `--exec-before-download`
pukkandan 1797b073ed
[utils] Use key `None` in `traverse_obj` to return as-is
Felix S 4afa3ec4b6
[extractor] Detect more subtitle codecs in MPD manifests ()
Authored by: fstirlitz
pukkandan abbeeebc4c
[outtmpl] Alternate form for `D` and fix suffix's case
Fixes: https://github.com/yt-dlp/yt-dlp/issues/2085#issuecomment-1002247689, https://github.com/yt-dlp/yt-dlp/pull/2132/files#r775729811
pukkandan 45d86abeb4
Allow unicode characters in `info.json`
Closes 
Pierre Mdawar f02d24d8d2
[utils] Fix `format_bytes` output for Bytes ()
Authored by: pukkandan, mdawar
pukkandan 352d5da812
[utils] Improve `parse_count`
Benedikt Wildenhain 4b4b7f746c
[OpenCast] Add extractors ()
Original PR: https://github.com/ytdl-org/youtube-dl/pull/26934
Authored by: bwildenhain, C0D3D3V
Luc Ritchie 4f3fa23e5a
[utils] Fix parsing `YYYYMMDD` dates in Nov/Dec ()
The date format `%Y%m%d%H%M` will successfully match against
one-digit month, day, hour, and minute strings, even though %m et al.
are documented as being zero-padded. So dates without time in
Nov/Dec may be wrongly parsed as dates in January with time.

This commit adds a format string of `%Y%m%d` to our supported date
format strings directly below (higher priority) its problematic relatives.

Closes 
Authored by: wlritchi
pukkandan b69fd25c25
[cleanup] Misc cleanup
Closes     
pukkandan e0fd95737d
[outtmpl] Add alternate forms `F`, `D`
and improve `id` detection

F = sanitize as filename (# = restricted)
D = add Decimal suffixes

Closes , 2081
The Hatsune Daishi adbc4ec4bb
[dash,youtube] Download live from start to end ()
* 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 
Authored by: nao20010128nao, pukkandan
Felix S d76d15a669
[utils] Update `std_headers` ()
* Update our chrome versions used for `User-Agent`s
* Drop the `Accept-Charset` header that no browser emits any more

Authored by: kikuyan, fstirlitz
The Hatsune Daishi 2814f12ba4
[skeb] Add extractor ()
Fixes: https://github.com/ytdl-org/youtube-dl/issues/30287
Authored by: nao20010128nao
pukkandan e3c7d49571
[compat] Suppress errors in enabling VT mode
Closes 
pukkandan 38d79fd16c
Use `parse_duration` for `--wait-for-video`
and some minor fix
pukkandan 43b2290658
Fix `--throttled-rate`
pukkandan ee8dd27a73
[cleanup] Add deprecation warnings
pukkandan f304da8a29
[cleanup] Misc cleanup
Closes , closes 
pukkandan f2ebc5c7be
Option `--wait-for-video` to wait for scheduled streams
pukkandan 282f570918
[utils] Fix error when copying `LazyList`
pukkandan c07a39ae8e
[utils] Fix `PagedList`
Bug in d8cf8d97a8
pukkandan c5e3f84972
[utils] Allow alignment in `render_table`
and add tests
pukkandan d8cf8d97a8
[utils] Fix `PagedList`
pukkandan c586f9e8de
[cleanup] minor fixes
pukkandan aa9369a2d8
[cleanup] Minor improvements to error and debug messages
pukkandan 582fad70f5
[outtmpl] Do not traverse `None`
Closes 
pukkandan 34921b4345
[utils] Add `join_nonempty`
Francesco Frassinelli 73673ccff3
[RaiplayRadio] Add extractors ()
Original PR: https://github.com/ytdl-org/youtube-dl/pull/21837
Authored by: frafra
pukkandan 9af98e17bd
[ffmpeg] Framework for feature detection
Related: , , https://github.com/ytdl-org/youtube-dl/pull/29581
pukkandan 31c49255bf
[ExtractAudio] Rescale --audio-quality correctly
Authored by: CrypticSignal, pukkandan
pukkandan 9bd979ca40
[utils] Parse `vp09` as vp9
pukkandan 16b0d7e621
[utils] Add `jwt_decode_hs256`
Code from 
Authored by: Ashish0804
pukkandan 0db3bae879
[extractor] Fix some errors being converted to `ExtractorError`
pukkandan 48f796874d
[utils] Create `DownloadCancelled` exception
as super-class of ExistingVideoReached, RejectedVideoReached, MaxDownloadsReached

Third parties can also sub-class this to cancel the download queue from a hook
pukkandan 08438d2ca5
[outtmpl] Add type `link` for internet shortcut files
and refactor related code
Closes 
pukkandan 7de837a5e3
[utils] Sanitize URL when determining protocol
Closes 
pukkandan 9f1a1c36e6
Separate `--check-all-formats` from `--check-formats`
Previously, `--check-formats` tested only the selected video formats, but ALL thumbnails
pukkandan ec11a9f4a2
[minicurses] Add more colors
Damiano Amatruda 17ec8bcfa9
[microsoftstream] Add extractor ()
Based on: https://github.com/ytdl-org/youtube-dl/pull/24649
Fixes: https://github.com/ytdl-org/youtube-dl/issues/24440
Authored by: damianoamatruda, nixklai
pukkandan d3c93ec2b7
Don't create console for subprocesses on Windows ()
Closes 
pukkandan aa7785f860
[utils] Standardize timestamp formatting code
Closes