RANA commited on
Commit
d34f1ab
1 Parent(s): 87fe3cc

scrapper no browser 2

Browse files
Files changed (1) hide show
  1. models/scrapper.py +2 -1
models/scrapper.py CHANGED
@@ -1,4 +1,5 @@
1
  import time
 
2
  from time import sleep
3
  from selenium import webdriver
4
  from selenium.webdriver.common.keys import Keys
@@ -10,7 +11,7 @@ posts_content = []
10
  def scrapper_func():
11
  options = FirefoxOptions()
12
  options.add_argument('--headless')
13
- browser = webdriver.Firefox(options=options, executable_path='geckodriver-v0.33.0-win32/geckodriver.exe')
14
  posts_content = []
15
 
16
  try:
 
1
  import time
2
+ import os
3
  from time import sleep
4
  from selenium import webdriver
5
  from selenium.webdriver.common.keys import Keys
 
11
  def scrapper_func():
12
  options = FirefoxOptions()
13
  options.add_argument('--headless')
14
+ browser = webdriver.Firefox(options=options, executable_path='geckodriver-v0.33.0-win32/geckodriver.exe', service_log_path=os.devnull)
15
  posts_content = []
16
 
17
  try: