Ignore unavailable elements

This commit is contained in:
Mr-Pine 2025-05-28 11:47:39 +02:00
parent 34564cedb4
commit b6b94c3d34
No known key found for this signature in database
GPG key ID: 5481659D1D983422
2 changed files with 8 additions and 0 deletions

View file

@ -30,6 +30,9 @@ ambiguous situations.
## Fixed ## Fixed
- Crawling of exercises with instructions - Crawling of exercises with instructions
- Don't download unavailable elements.
Elements that are unavailable (for example, because their availability is
time restricted) will not download the HTML for the info page anymore.
## 3.8.2 - 2025-04-29 ## 3.8.2 - 2025-04-29

View file

@ -329,6 +329,11 @@ instance's greatest bottleneck.
# directory escape attacks. # directory escape attacks.
element_path = PurePath(parent_path, element.name) element_path = PurePath(parent_path, element.name)
# This is symptomatic of no access to the element, for example, because
# of time availability restrictions.
if "cmdClass=ilInfoScreenGUI" in element.url and "cmd=showSummary" in element.url:
return None
if element.type in _VIDEO_ELEMENTS: if element.type in _VIDEO_ELEMENTS:
if not self._videos: if not self._videos:
log.status( log.status(