From 849669dbed1c1c1e3e036bca8c4085575e642e96 Mon Sep 17 00:00:00 2001 From: InvalidUsernameException Date: Tue, 27 May 2025 18:29:46 +0200 Subject: [PATCH] Document that chapter end_time is optional --- yt_dlp/extractor/common.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/yt_dlp/extractor/common.py b/yt_dlp/extractor/common.py index 4356f9b8c..f39d94db3 100644 --- a/yt_dlp/extractor/common.py +++ b/yt_dlp/extractor/common.py @@ -387,6 +387,9 @@ class InfoExtractor: chapters: A list of dictionaries, with the following entries: * "start_time" - The start time of the chapter in seconds * "end_time" - The end time of the chapter in seconds + (optional, defaults to the start_time of + the next chapter or the end of the video + if this is the last chapter) * "title" (optional, string) heatmap: A list of dictionaries, with the following entries: * "start_time" - The start time of the data point in seconds