{"repo":"alejandrocq/ComedoresUGRbot","free":true,"listed":false,"github":"https://github.com/alejandrocq/ComedoresUGRbot","clone":"git clone https://github.com/alejandrocq/ComedoresUGRbot.git","description":"Telegram bot to check the menu of Universidad de Granada dining hall.","language":"Python","stars":17,"topics":["telegram-bot","telegram","python","javascript","ugr","puppeteer","bot"],"license":"GPL-3.0","category":"scrapers-browser-automation","readme_excerpt":"ComedoresUGRbot http://telegram.me/ComedoresUGRbot Telegram bot to check the menu of Universidad de Granada dining hall. It works thanks to pyTelegramBotAPI and puppeteer. Puppeteer is used to launch a headless Chrome browser, find menu tables and save them as png images. This implementation can be maintained more easily, because scu.ugr.es DOM has been changing a lot and parse the data in the tables seems to be more problematic. I made a request to them in order to get a simple JSON API for developers and they answered that they would consider it, but for the moment it's necessary to parse scu.ugr.es DOM one way or another. Installation Option 1: Docker (Recommended) The easiest way to run the bot is using Docker. This handles all dependencies automatically: 1. Create a .env file from the example: 2. Edit .env and add your bot token and the UGR dining hall URL: 3. Create the data directory: 4. Start the bot: Useful commands: - View logs: docker-compose logs -f - Stop bot: docker-compose down - Restart bot: docker-compose restart - Rebuild after changes: docker-compose up -d --build Option 2: Manual Installation First of all, you need Python 3 correctly installed on your machine . 1. Create and activate a virtual environment: 2. Install Python dependencies: 3. Install Node.js dependencies: 4. Test the renderer (optional): Verify that menu tables are being saved in ./images-new folder. 5. Configure environment variables: Create a .env file: Edit it with your configuration: 6. ","default_branch":null,"files":null,"tree":[],"storefront":"/r/alejandrocq","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/alejandrocq/ComedoresUGRbot/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}