GitHub Classroom Workflow
GitHub Classroom Workflow
Creating with AI in the Loop — Assignment workflow (repeat for each assignment)
This guide covers the steps you’ll follow for each GitHub Classroom assignment:
- Accept the assignment and clone the repo
- Create a virtual environment and install dependencies
- Do the work
- Commit and push (submit)
Prerequisite: Complete the one-time setup first: Initial Setup (Windows) | Initial Setup (macOS)
1) Accept the GitHub Classroom assignment
- Click the Classroom invite link (from the Assignments page).
- Click Accept assignment.
- GitHub creates a repo for you and takes you to it.
2) Clone the repo
Copy the repo HTTPS URL from GitHub (click Code → HTTPS).
- In VS Code:
Ctrl+Shift+P→Git: Clone - Paste the URL
- Pick a folder
- Open the repo when prompted
cd C:\Users\YourName\Documents
git clone <PASTE-REPO-URL-HERE>
cd <REPO-FOLDER>
code .cd ~/Documents
git clone <PASTE-REPO-URL-HERE>
cd <REPO-FOLDER>
code .3) Create a virtual environment and install dependencies
Open a terminal in VS Code: Terminal → New Terminal
py -3.13 -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install --upgrade pip
pip install -r requirements.txtIf PowerShell blocks the activation script:
py -3.13 -m venv .venv
.\.venv\Scripts\activate.bat
python -m pip install --upgrade pip
pip install -r requirements.txtpython3.13 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
pip install -r requirements.txtIf the repo has a pyproject.toml or setup.py, also run:
pip install -e .Verify the venv is active
python --version
where pythonThe where python output should show a path inside .venv.
python --version
which pythonThe which python output should show a path inside .venv.
4) Sanity checks
If the repo has tests:
pytest -qOr run a quick Python check:
python -c "print('Hello from Python!')"5) Do the work
Complete the assignment according to the instructions in the repo’s README.
6) Commit and push (submit)
Typical “submission” is commit + push. Autograding (if enabled) runs after you push.
- Open the Source Control panel (left sidebar)
- Stage changes (click
+next to files) - Enter a commit message
- Click Commit
- Click Sync Changes (pushes to GitHub)
git status
git add .
git commit -m "Complete submission"
git pushAfter pushing, check your repo on GitHub. If autograding is enabled, you’ll see a ✅ or ❌ next to your commit.
Troubleshooting
git push permission/auth errors
- Make sure you accepted the assignment with the correct GitHub account
- Retry push and complete the browser sign-in flow if prompted
- Check that the repo URL matches your GitHub username
If issues persist, run these commands and include the output in your help request:
git remote -v
git config --global credential.helper
git config --show-origin --get-all credential.helperPowerShell won’t activate .venv (execution policy)
Use Command Prompt instead:
.\.venv\Scripts\activate.batOr (advanced) allow local scripts in PowerShell:
Set-ExecutionPolicy -Scope CurrentUser RemoteSignedrequirements.txt not found
Not all assignments have a requirements.txt. Skip the pip install -r requirements.txt step if the file doesn’t exist.
Tests failing after push
- Read the error message in the GitHub Actions log
- Fix the issue locally
- Commit and push again
Quick reference: common commands
| Task | Windows (PowerShell) | macOS |
|---|---|---|
| Create venv | py -3.13 -m venv .venv |
python3.13 -m venv .venv |
| Activate venv | .\.venv\Scripts\Activate.ps1 |
source .venv/bin/activate |
| Deactivate venv | deactivate |
deactivate |
| Install deps | pip install -r requirements.txt |
pip install -r requirements.txt |
| Run tests | pytest -q |
pytest -q |
| Commit all | git add . && git commit -m "msg" |
git add . && git commit -m "msg" |
| Push | git push |
git push |