I initiated and close phantomjs
in Python with the following
from selenium import webdriver
driver = webdriver.PhantomJS()
driver.get(url)
html_doc = driver.page_source
driver.close()
yet after the script ends execution I still find an instance of phantomjs
in my Mac Activity Monitor. And actually every time I run the script a new process phantomjs
is created.
How should I close the driver?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…