from selenium import webdriver
phantomJSPath = 'C:\\my working dir\\Lib\\phantomjs.exe'
desiredCap = {'platform': 'ANY', 'browserName': 'phantomjs', 'version': '',
    'javascriptEnabled': True}
browser = webdriver.PhantomJS(executable_path=phantomJSPath, port=0,
    desired_capabilities=desiredCap)
Python — Selenium PhantomJS — ошибка JSON