mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-09-03 08:35:32 +00:00
[cleanup] Misc (#11216)
- Add Python 3.13 to CI, finalize 3.13 support - Remove Python 3.8 from CI in preparation for removing 3.8 support - Document that PyPy3.8 and PyPy3.9 are no longer supported - Usual documentation fixes and code cleanup Closes #8248, Closes #11146, Closes #11149, Closes #11211 Authored by: Grub4K, grqz, DTrombett, KarboniteKream, bashonly, mikkovedru, seproDev Co-authored-by: N/Ame <173015200+grqz@users.noreply.github.com> Co-authored-by: DTrombett <d@trombett.org> Co-authored-by: =?UTF-8?q?Klemen=20Ko=C5=A1ir?= <klemen.kosir@kream.io> Co-authored-by: bashonly <88596187+bashonly@users.noreply.github.com> Co-authored-by: Mikko Vedru <mikko.vedru@gmail.com> Co-authored-by: sepro <sepro@sepr0.com>
This commit is contained in:
@ -55,7 +55,7 @@ def traverse_obj(
|
||||
The keys in the path can be one of:
|
||||
- `None`: Return the current object.
|
||||
- `set`: Requires the only item in the set to be a type or function,
|
||||
like `{type}`/`{type, type, ...}/`{func}`. If a `type`, return only
|
||||
like `{type}`/`{type, type, ...}`/`{func}`. If a `type`, return only
|
||||
values of this type. If a function, returns `func(obj)`.
|
||||
- `str`/`int`: Return `obj[key]`. For `re.Match`, return `obj.group(key)`.
|
||||
- `slice`: Branch out and return all values in `obj[key]`.
|
||||
@ -75,7 +75,7 @@ def traverse_obj(
|
||||
|
||||
`tuple`, `list`, and `dict` all support nested paths and branches.
|
||||
|
||||
@params paths Paths which to traverse by.
|
||||
@params paths Paths by which to traverse.
|
||||
@param default Value to return if the paths do not match.
|
||||
If the last key in the path is a `dict`, it will apply to each value inside
|
||||
the dict instead, depth first. Try to avoid if using nested `dict` keys.
|
||||
|
Reference in New Issue
Block a user