Scrape chat content from TakeLessons.com
Project description
Scrape the chat logs from TakeLessons
What is this?
If you noticed that TakeLessons doesn't have an API or a way to export your own data you can use this package to get at it.
How do I use it?
Prerequisites
- Install Chrome
- Find the correct selenium driver version for your install here
- Add it to PATH or make a note of where it is
pip install takelessons-scraper
Example Usage:
# Assume some db object you can save your data to
db = SomeDBStore()
from takelessons_scraper import TakeLessonsScraper
chromedriver_path = '/path/to/chromedriver'
username = 'username'
password = 'password'
scraper = TakeLessonsScraper(chromedriver_path)
# login to load cookies behind scenes
scraper.login(username, password)
# get a block of chat data up to date
chat_date = '2020-01-01'
# you may need to sleep a bit
chat_log = scraper.get_chat_history(chat_date) # Chat obj, can get raw json back
db.save(chat_log)
Notes:
Please consider this a hobby project to be used as reference. Since it is a scraper I expect it to fail as regularly as the source is updated... which could be at any time and not within my control.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for takelessons-scraper-0.0.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | c7b0933878e1368936e0cc050592b37b3e4d873d3246cfccde2eeedcf457e8d8 |
|
MD5 | 346ef61645bfe2dfb8d3c4f440613ba3 |
|
BLAKE2b-256 | cdc0d3a145ae29b0478c85991c689af91e3dd022846c162b508d865d9d74f36d |
Close
Hashes for takelessons_scraper-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 428254bb11fea99c2661c83e6e86e4b85cef6f74969980b145835ae05d2c0052 |
|
MD5 | 7c8fca142f8cf6944cfc06d9d0af521c |
|
BLAKE2b-256 | 989a1086fa97cc2afa6a8994917dfa94005c2732cebcc3eb5aff2c116795c5b6 |