How vishnuuuuuu/job_scrapper works
Main Components
• Telegram Bot Interface – The core communication channel with users. This includes handling commands (e.g., /start, /help, /categories, /getjobs) and managing conversations.
• Scraper Module – The component that handles fetching and parsing job postings from the target website. This is encapsulated primarily in scraper.py (and potentially invoked or extended in chatis.py).
• Configuration & Setup Component – Responsible for loading configuration data from the config.json file (which is created by hand per README instructions). This includes the Telegram bot token, target URL, date formatting, and time window for job filtering.
• Job Filtering & Notification Handler – The logic that filters scraped job postings based on qualification preferences and ensures that only recent jobs (from the last 24 hours) are pushed to interested users. It also deals with scheduling auto-deletion of messages after 30 minutes.
• Deployment and Environment Management – Although the file structure itself is simple, the README indicates that the bot is designed to be easily deployable (for example on Railway.app) by leveraging environment variables and simple commands.
Relationships & Interactions
• The main entry point (main.py) is likely the orchestrator that initializes the Telegram bot, reads the config settings, and integrates with the scraper module.
• When a user sends a command via Telegram, the bot (via main.py and potentially chatis.py) processes the input and may trigger a scraping operation in scraper.py.
• The scraper module connects to the target website, retrieves job postings, and returns the data to the bot.
• The filtering logic then uses the user’s qualification preferences (possibly managed and stored from previous command interactions) to parse relevant job entries.
• If jobs meet the criteria, they are sent back to the user through the Telegram API. Additionally, a mechanism is in place to auto-delete messages after 30 minutes.
Architectural Patterns & Technologies
• Separation of Concerns: Notice that the bot commands, scraping logic, and configuration management are all segregated in separate modules (main.py, scraper.py, chatis.py).
• Frameworks/Libraries: Since the project is in Python and involves Telegram integration, expect to see usage of a Telegram bot library (like python-telegram-bot or Telepot) along with requests or BeautifulSoup for web scraping.
• Deployment Considerations: Highlight that the project is ready for deployment on Railway.app, stating that environment variables are used and the start command is just “python main.py”.