Installation¶
Installing Persine¶
Installation of Persine isn’t too hard, it can be installed using pip:
pip install persine
In order to do its job, Persine will automatically install a lot of dependencies! These include:
Selenium to control the browser
BeautifulSoup for browsing/scraping
pandas for data analysis
pillow for processing screenshots
After you install Persine, you aren’t done yet: because Persine controls a browser, you need to install both a browser as well as the software that connects Python to the browser.
Installing Chrome¶
Persine uses Google Chrome to drive around the internet and pretend to be a user. I would love to switch to Firefox but it has its own problems.
You’ll want to make sure it’s in a normal place (for example, not just living in your “Downloads” folder).
Installing ChromeDriver¶
You will need to install ChromeDriver to allow Selenium to control Chrome. You can read the ChromeDriver getting started page but I’ve also included installing instructions below.
Note that every time you update Chrome you’ll need to update ChromeDriver.
Installing ChromeDriver on OS X¶
The easiest way to install ChromeDriver on OS X is using homebrew:
brew install --cask chromedriver
Alternatively, you can follow these steps:
Visit the ChromeDriver website
Click the “latest stable release” link
Download chromedriver_mac64.zip
Unzip it, revealing a file called chromedriver (no extension)
Move this file into your PATH. I typically put it in /usr/local/bin.
Installing ChromeDriver on Windows¶
Follow the following steps to install ChromeDriver on Windows:
Visit the ChromeDriver website
Click the “latest stable release” link
Download chromedriver_win32.zip
Unzip it, revealing a file called chromedriver.exe (no extension)
Move this file into your PATH. In the spirit of anarchy I just put it in C:Windows.
Installing ChromeDriver on Debian/Ubuntu¶
It’s the easiest of them all:
apt install chromium-chromedriver