From 3d75c6d10713334a97b9d6954226a623c7e68f6c Mon Sep 17 00:00:00 2001 From: techtanic Date: Wed, 3 Jul 2024 23:33:32 +0530 Subject: [PATCH] chore: Remove unnecessary code for saving data to file --- base.py | 2 -- gui.py | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/base.py b/base.py index 77ef5c1..b3be051 100644 --- a/base.py +++ b/base.py @@ -573,8 +573,6 @@ def remove_duplicate_courses(self): existing_links = set() new_data = {} data = self.scraped_data - with open("test/data.json", "w") as f: - json.dump(data, f, indent=4) for key in data: new_data[key] = [] for title, link in data[key]: diff --git a/gui.py b/gui.py index ffa8706..e4169be 100644 --- a/gui.py +++ b/gui.py @@ -97,7 +97,7 @@ def scrape(): e = traceback.format_exc() main_window.write_event_value( "Error", - e + f"\n\n{udemy.link}\n{udemy.title}" + f"|:|Unknown Error {VERSION}", + f"{e}\n\nVersion:{VERSION}\nLink:{getattr(udemy, 'link', 'None')}\nTitle:{getattr(udemy, 'title','None')}", )