From 93d36eb338568c7a7df9fb97797cd2d8cdba7ab1 Mon Sep 17 00:00:00 2001 From: Alain Hernandez Date: Sat, 19 Dec 2020 19:09:53 -0500 Subject: [PATCH] Remove collection selectors since they don't work anyways This is specifically the selectors next to collections (List, gallery, timeline, etc.) --- loconotion/notionparser.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/loconotion/notionparser.py b/loconotion/notionparser.py index 48a7541..8d17506 100644 --- a/loconotion/notionparser.py +++ b/loconotion/notionparser.py @@ -342,6 +342,10 @@ class Parser: for vendors_css in soup.find_all("link", href=lambda x: x and "vendors~" in x): vendors_css.decompose() + # collection selectors (List, Gallery, etc.) don't work, so remove them + for collection_selector in soup.findAll("div", {"class": "notion-collection-view-select"}): + collection_selector.decompose() + # clean up the default notion meta tags for tag in [ "description",