PhantomJS with Selenium: Message: 'phantomjs' executable needs to be in PATH
问题 I having trouble installing PhantomJS to my project Following the suggestions from the similar question from so I defined the $PATH variable with executable path cd Users/zkid18/project/venv/venv_name/lib/python3.6/site-packages/phantomjs-2.1.1/bin export PATH=$PWD Then I try to create a driver with a virtual browser import from selenium import webdriver browser = webdriver.PhantomJS() On this step I got an error No such file or directory: 'phantomjs': 'phantomjs' What I am missing? 回答1: You