Zombie processes, quot parser issue
This commit is contained in:
@@ -88,8 +88,11 @@ class MissingKidsFetcher():
|
|||||||
|
|
||||||
# Release memory
|
# Release memory
|
||||||
try:
|
try:
|
||||||
driver.close()
|
driver.quit() #driver.close()
|
||||||
|
time.sleep(1)
|
||||||
|
# import atexit
|
||||||
|
# atexit.register(driver.quit) # Will always be called on exit
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.warning("Exception while closing driver: {}".format(str(e)), exc_info=True)
|
logger.warning("Exception while closing/quitting driver: {}".format(str(e)), exc_info=True)
|
||||||
|
|
||||||
return set_urls
|
return set_urls
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ class FetchParser():
|
|||||||
url_host_clean = obj_search.search.replace("www.", "").replace("http://", "").replace("https://", "")
|
url_host_clean = obj_search.search.replace("www.", "").replace("http://", "").replace("https://", "")
|
||||||
# Ensure URL host in URL
|
# Ensure URL host in URL
|
||||||
raw_urls = [u for u in raw_urls if url_host_clean in u]
|
raw_urls = [u for u in raw_urls if url_host_clean in u]
|
||||||
|
|
||||||
|
# Clean if ends with """
|
||||||
|
raw_urls = [u.replace(""", "") if u.endswith(""") else u for u in raw_urls]
|
||||||
|
|
||||||
return raw_urls
|
return raw_urls
|
||||||
|
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ services:
|
|||||||
container_name: fetcher_app_selenium
|
container_name: fetcher_app_selenium
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
shm_size: 512mb
|
shm_size: 512mb
|
||||||
|
init: true # For zombie processes
|
||||||
environment:
|
environment:
|
||||||
- SELENIUM_SLEEP_PER_PAGE=${SELENIUM_SLEEP_PER_PAGE}
|
- SELENIUM_SLEEP_PER_PAGE=${SELENIUM_SLEEP_PER_PAGE}
|
||||||
- PATH_LOGS_DIRECTORY=${PATH_LOGS_DIRECTORY}
|
- PATH_LOGS_DIRECTORY=${PATH_LOGS_DIRECTORY}
|
||||||
|
|||||||
Reference in New Issue
Block a user