Required CSV Format
The CSV parsing logic inbot.py:192 expects a specific structure:
File Structure Requirements
- Rows 1-3: Header information (skipped by parser)
- Row 4: Month names in French (JANVIER, FÉVRIER, MARS, etc.)
- Rows 5-35: Schedule data (maximum 32 rows processed)
Column Structure
Each month should have 3 consecutive columns:- Day column: Day of week abbreviation (L, M, Me, J, V, S, D)
- Morning column: Morning class code or “FERIE” for holidays
- Afternoon column: Afternoon class code or leave empty
| (ignored) | JANVIER | FÉVRIER | MARS | ||||||
|---|---|---|---|---|---|---|---|---|---|
| (ignored) | Jour | Matin | Après-midi | Jour | Matin | Après-midi | Jour | Matin | Après-midi |
| Day 1 | L | UTC501 | UTC502 | L | GDN100 | L | NFP121 | ||
| Day 2 | M | UTC503 | M | SEC102-FC | ANG320 | M | RSX102 |
Month Name Mapping
The bot maps English month names to French (bot.py:37-42):
Day Abbreviations
The parser recognizes these day abbreviations (bot.py:284-312):
- L → Lundi (Monday)
- M → Mardi (Tuesday) or Mercredi (Wednesday) depending on context
- Me → Mercredi (Wednesday)
- J → Jeudi (Thursday)
- V → Vendredi (Friday)
- S → Samedi (Saturday)
- D → Dimanche (Sunday)
The letter “M” is context-aware: if the previous day was “Lundi”, it becomes “Mardi”. Otherwise, it becomes “Mercredi”.
Course Codes
You can use any course code in the morning/afternoon columns. The bot has a predefined mapping (bot.py:22-35) for common courses:
Special Values
- FERIE: Marks a public holiday (both morning and afternoon become “FERIE”)
- Empty cells: Displayed as “Hors jour de cours” (No class day)
- SEM prefix: Codes starting with “SEM” are ignored/treated as empty
Setup Instructions
Structure the sheet
Format your sheet with:
- Rows 1-3: Headers/metadata (optional, will be skipped)
- Row 4: Month names in French uppercase
- Rows 5+: Daily schedule data
Fill in schedule data
Add your schedule:
- Use day abbreviations (L, M, Me, J, V)
- Enter course codes for morning and afternoon slots
- Use “FERIE” for holidays
- Leave cells empty for free periods
Make sheet publicly accessible
File → Share → Change to “Anyone with the link”Set permission to “Viewer” so the bot can read the data.
Get the CSV export URL
Your CSV export URL format:Replace Your CSV export URL is:
YOUR_SHEET_ID with the actual ID from your sheet’s URL.Example:
If your sheet URL is:Test the CSV export
Open the CSV export URL in your browser. It should download a CSV file with your schedule data.
Example Google Sheets Template
Here’s a minimal working example: | Bot Planning Schedule | | Academic Year 2026 | | (leave this row empty) | | JANVIER | | | FÉVRIER | | | | Jour | Matin | Après-midi | Jour | Matin | Après-midi | | L | UTC501 | UTC502 | L | GDN100 | SEC102-FC | | M | UTC503 | | M | | ANG320 | | Me | UTC505 | NFP107 | Me | NFP121 | | | J | | UTC502 | J | FERIE | | | V | ANG320 | | V | RSX102 | UTC505 |Troubleshooting
Month not found error:- Verify month names are in French and uppercase
- Check there are no extra spaces
- Ensure month names are in row 4 (after 3 skipped rows)
- Verify day abbreviations are correct (L, M, Me, J, V)
- Check for case sensitivity (should be lowercase in your sheet)
- Ensure the sheet is publicly accessible
- Verify the CSV export URL works in a browser
- Check that you have data in rows 5-35 (within the 32-row limit)