From 0629542d34300ed7e91bf046cfc95df8eeef2245 Mon Sep 17 00:00:00 2001 From: Isabelle Wang Date: Wed, 10 Jul 2024 16:31:08 -0700 Subject: [PATCH] Updated the imports --- MarketPlaces/Initialization/markets_mining.py | 3 +++ MarketPlaces/Initialization/prepare_parser.py | 7 ++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/MarketPlaces/Initialization/markets_mining.py b/MarketPlaces/Initialization/markets_mining.py index 70f0134..3e8a6bb 100644 --- a/MarketPlaces/Initialization/markets_mining.py +++ b/MarketPlaces/Initialization/markets_mining.py @@ -26,6 +26,7 @@ from MarketPlaces.GoFish.crawler_selenium import crawler as crawlerGoFish from MarketPlaces.ZeroDay.crawler_selenium import crawler as crawlerZeroDay from MarketPlaces.Torzon.crawler_selenium import crawler as crawlerTorzon from MarketPlaces.DarkMarket.crawler_selenium import crawler as crawlerDarkMarket +from MarketPlaces.DarkDock.crawler_selenium import crawler as crawlerDarkDock from MarketPlaces.SilkRoad4.crawler_selenium import crawler as crawlerSilkRoad4 import configparser @@ -142,6 +143,8 @@ if __name__ == '__main__': crawlerTorzon() elif mkt == "DarkMarket": crawlerDarkMarket() + elif mkt == 'DarkDock': + crawlerDarkDock() elif mkt == "SilkRoad4": crawlerSilkRoad4() diff --git a/MarketPlaces/Initialization/prepare_parser.py b/MarketPlaces/Initialization/prepare_parser.py index 3900f03..0b0a002 100644 --- a/MarketPlaces/Initialization/prepare_parser.py +++ b/MarketPlaces/Initialization/prepare_parser.py @@ -29,6 +29,7 @@ from MarketPlaces.GoFish.parser import * from MarketPlaces.ZeroDay.parser import * from MarketPlaces.DarkMarket.parser import * from MarketPlaces.DarkDock.parser import * +from MarketPlaces.SilkRoad4.parser import * from MarketPlaces.Classifier.classify_product import predict from Translator.translate import translate @@ -172,7 +173,9 @@ def parse_listing(marketPlace, listingFile, soup, createLog, logFile): elif marketPlace == "DarkMarket": rw = darkmarket_listing_parser(soup) elif marketPlace == "DarkDock": - rw = darkdock_listing_parser(soup) + rw = darkdock_listing_parser() + elif marketPlace == "SilkRoad4": + rw = silkroad4_listing_parser() else: print("MISSING CALL TO LISTING PARSER IN PREPARE_PARSER.PY!") raise Exception @@ -235,6 +238,8 @@ def parse_description(marketPlace, descriptionFile, soup, createLog, logFile): rmm = darkmarket_description_parser(soup) elif marketPlace == "DarkDock": rmm = darkdock_description_parser(soup) + elif marketPlace == "SilkRoad4": + rmm = silkroad4_description_parser() else: print("MISSING CALL TO DESCRIPTION PARSER IN PREPARE_PARSER.PY!") raise Exception