Welcome to the Pyramid Performance Tracker project! This application tracks and displays competitive programming performance across multiple platforms for students from various colleges.
- Scrapes data from multiple platforms: CodeChef, Codeforces, GeeksforGeeks, HackerRank, and LeetCode.
- Generates a comprehensive leaderboard in Excel and CSV formats.
- Allows real-time updates and viewing of participantsβ performance.
-
Clone the repository:
git clone https://github.com/Pyramid-IT-Learn/Pyramid-Performance-Tracker.git cd Pyramid-Performance-Tracker -
Create a Virtual Environment: Make sure you have Python and
venvinstalled:python -m venv venv
-
Activate the Virtual Environment:
- On Windows:
venv\Scripts\activate
- On macOS/Linux:
source venv/bin/activate
- On Windows:
-
Install Required Packages: Install the necessary packages:
pip install -r requirements.txt
To configure the application, you'll need to set several environment variables. You can create a .env file in the root directory or set these variables in your environment:
CODEFORCES_KEY=your_codeforces_api_key
CODEFORCES_SECRET=your_codeforces_api_secret
GIT_USERNAME=your_github_username
GIT_PASSWORD=your_github_password
GFG_USERNAME=your_geeksforgeeks_username
GFG_PASSWORD=your_geeksforgeeks_password
CODECHEF_CLIENT_ID=your_codechef_client_id
CODECHEF_CLIENT_SECRET=your_codechef_client_secret
DB_PASSWORD=your_mongodb_password
- MongoDB Connection:
mongodb://myUserAdmin:<DB_PASSWORD>@your_mongodb_host:27017 - DB_NAME: Keep it as
Pyramidor change it as needed for different colleges. - USERS_COLLECTION: Change this name for different batches; currently set to
Pyramid-2026-LEADERBOARD.
To manage the Pyramid Performance Tracker, follow these steps:
-
Verify Users: This will download the CSV file specified in the config if it doesn't exist.
python main.py --verify all
-
Upload Data to Database:
python main.py --upload
-
Scrape Data: Collect data from all platforms.
python main.py --scrape all
-
Clear Logs and Reports (optional):
python main.py --clear
Ensure you run the verification and upload steps before scraping to keep your data updated!
This will fetch user data and generate reports in the reports directory.
You can view the latest leaderboards and track participant performance at Pyramid Leaderboards.
The Pyramid Performance Tracker project uses GitHub Actions to automate key tasks:
- Trigger: Manually.
- Purpose: Scrapes user data from coding platforms and builds the leaderboard report.
- Trigger: Manually select platforms.
- Purpose: Scrapes data from specific platforms (CodeChef, Codeforces, etc.) or all at once.
Needs to be performed first.
- Trigger: Manually select platforms.
- Purpose: Verifies user handles and uploads the data to the database.
- Trigger: Scheduled. (01:30 AM IST on Tuesday and Saturday)
- Purpose: To generate the data for users in the database continuously.
To trigger workflows, go to the GitHub Actions tab in your repository and select the desired workflow.
A massive shoutout to the incredible gabyah92 for their brilliant vision and exceptional contributions! π Your original project laid the foundation for this leaderboard, and your dedication to the coding community inspires us all. Thank you for sharing your knowledge and creativityβthis project wouldnβt be possible without you! π