Scrape with Selenium
On repl.it add Selenium, the 3rd party Python library
Click on the three (3) dots to show the hidden files.
Add two packages that will enable selenium to scrape data.
{ pkgs }: {
deps = [
pkgs.python38Full
pkgs.chromium
pkgs.chromedrive
];
env = {
PYTHON_LD_LIBRARY_PATH = pkgs.lib.makeLibraryPath [
# Neded for pandas / numpy
pkgs.stdenv.cc.cc.lib
pkgs.zlib
# Needed for pygame
pkgs.glib
# Needed for matplotlib
pkgs.xorg.libX11
];
PYTHONBIN = "${pkgs.python38Full}/bin/python3.8";
LANG = "en_US.UTF-8";
};
}
from selenium import webdriver
# the chrome class of the webdriver makes everything possible
driver = webdriver.Chrome()