-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmain.py
29 lines (24 loc) · 1.08 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
from new_scraper import Scraper
from httpserver import RESTful
from interface import Interface
import threading
class mainProgram:
def __init__(self):
self.program = Interface()
self.server = RESTful(self.program)
non_web3 = ['elonmusk', 'POTUS', 'BillGates', 'sama', 'zlj517']
big_orgs = ['paradigm','a16z','sequoia','Stepnofficial','MantaNetwork','okxweb3','binance','kucoincom','cz_binance','twobitidiot']
projects = ['Nakamigos', 'TheMuppethShow', 'Cat_Mouse_game', 'Ronin_Network', 'ZooDAO']
research = ['zachxbt', 'jphackworth42', 'drakefjustin', 'BTC__options']
self.accounts = non_web3 + big_orgs + projects + research
self.scraper = Scraper(self.program, listOfAccounts = self.accounts)
def run_scraper(self):
self.scraper.run()
self.scraper.save_tweets_to_csv()
def run(self):
print("Running scraper thread")
scraper_thread = threading.Thread(target=self.run_scraper)
scraper_thread.start()
print("Running Flask server")
self.server.run()
mainProgram().run()