-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathscrap_data.py
More file actions
38 lines (28 loc) · 761 Bytes
/
Copy pathscrap_data.py
File metadata and controls
38 lines (28 loc) · 761 Bytes
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
30
31
32
33
34
35
36
37
38
import argparse
from src.web_scrap import (
application_info,
# block_info, flat_info,
# project_info, project_link
)
from src.constants import APP_INFO_PATH
def parse_args():
parser = argparse.ArgumentParser()
parser.add_argument(
'--app_only', type=str,
choices=['yes', 'no'],
default='yes',
help="When set to `yes`, will get only the latest application info"
)
args = parser.parse_args()
return args
def main():
args = parse_args()
app_info = application_info.get_data()
app_info.to_csv(APP_INFO_PATH, index=False)
if args.app_only == 'yes':
return
else:
# TODO: Add remaining scrapping functions
pass
if __name__ == "__main__":
main()