
Data collection script and telegram-bot to monitor the local Boulderhaus' booking state. It shows the currently booked spots for each timeslot and the average number of visitors during the whole stay.
-
Set up a Telegram-Bot (https://core.telegram.org/bots)
-
git clone https://github.com/david-fischer/boulder-stats.git cd boulder-stats pip install . boulder_stats bot setup boulder_stats bot start & boulder_stats data schedule
-
add bot to conversation
-
/unlock <UNLOCK_PW>
Now the bot responds to commands in this chat.
Bot commands:
/plot <args>
/unlock <pw>
Help text of Command line interface to control bot and data-collection:
> boulder_stats -h
Usage: boulder_stats [OPTIONS] COMMAND [ARGS]...
Collect data and control telegram bot, that can plot the data.
Options:
-h, --help Show this message and exit.
Commands:
bot Call bot functions.
data Call data functions.
> boulder_stats bot -h
Usage: boulder_stats bot [OPTIONS] COMMAND [ARGS]...
Call bot functions.
Options:
-h, --help Show this message and exit.
Commands:
setup Set token and password of bot.
start Start the bot.
> boulder_stats data -h
Usage: boulder_stats data [OPTIONS] COMMAND [ARGS]...
Call data functions.
Options:
-h, --help Show this message and exit.
Commands:
collect Collect data for the next 7 days.
schedule Use scheduler to periodically collect data for the next 7 days.
- apscheduler - In-process task scheduler with Cron-like capabilities
- attrs - Classes Without Boilerplate
- beautifulsoup4 - Screen-scraping library
- click - Composable command line interface toolkit
- jinja2 - A very fast and expressive template engine.
- matplotlib - Python plotting package
- numpy - NumPy is the fundamental package for array computing with Python.
- pandas - Powerful data structures for data analysis, time series, and statistics
- python-telegram-bot - We have made you a wrapper you can't refuse
- selenium - Python bindings for Selenium
- setuptools - Easily download, build, install, upgrade, and uninstall Python packages
- xvfbwrapper - run headless display inside X virtual framebuffer (Xvfb)