Skip to main content

CourseLink CSV grading helper

Project description

CourseLink CSV Grading Helper

This project is a Typer CLI for CourseLink CSV exports. The source lives under src/, and the packaged CLI command is courselink-helper. It uses color-coded terminal output via rich to make statuses and workflow steps easier to follow.

What it does

Option 1 (option1)

  • Loads a CourseLink export CSV.
  • If fzf is installed, prompts whether to use fzf for CSV selection.
  • Detects the assignment grade column by matching "Points Grade" in the header.
  • Creates a new CSV that is ready to import by removing rows where the grade cell is empty.
  • Keeps all columns and headers unchanged for remaining rows, including End-of-Line Indicator.
  • Keeps valid 0 grades.

Option 2 (option2)

  • Opens a CSV and runs an interactive grading harness.
  • If fzf is installed, prompts whether to use fzf for CSV and student selection.
  • Without fzf, the built-in CSV picker starts at the current working directory by default and behaves like a simple directory tree:
    • arrow keys move the selection
    • Enter opens a directory or selects a CSV
    • Backspace moves to the parent directory
  • --root PATH lets you override where CSV browsing starts.
  • In fzf mode, student matching uses case-insensitive fuzzy matching against a hidden search key (name, username, IDs) while showing a clean display column for stable selection.
  • Uses ranked fuzzy search (live filter, arrow keys, Enter) to find students by:
    • Last Name
    • First Name
    • Username
    • OrgDefinedId
  • Prioritizes stronger matches (for example, Cole should rank above weaker partial matches).
  • If you press Enter after typing a close match (even without explicitly accepting completion text), it resolves to the best student match.
  • Displays Username and OrgDefinedId without the leading # for readability (the saved CSV still keeps original values).
  • If fzf selection is cancelled or fails, it falls back to the built-in picker.
  • Lets you enter decimal grades and validates:
    • grade is not empty
    • grade is numeric
    • grade is not negative
    • grade is <= MaxPoints parsed from header text like:
      • Homework 6 Points Grade <Numeric MaxPoints:12 Weight:1>
  • Autosaves after every entered grade into a progress CSV in the current directory.
  • Supports resume by reopening that progress CSV.
  • Keyboard controls:
    • Ctrl-Q: quit
    • Ctrl-B: jump to previously graded student

Install

Install from PyPI

After publishing, the simplest global installs are:

uv tool install courselink-grader
# or
pipx install courselink-grader

That puts courselink-helper on your PATH, so you can run it from any directory.

Install from this repo during development

uv tool install .
# or, for a project-local environment:
uv sync

Usage

Run courselink-helper from the directory that contains your grading files, or pass --root to browse somewhere else. CSV files can live directly in the current directory or in nested folders such as ./grading/assignments/assignment1.csv.

Run menu mode (choose option 1 or 2):

courselink-helper

Direct command usage:

# Option 1: ready-to-import CSV
courselink-helper option1
courselink-helper option1 --csv "grading/assignments/assignment1.csv" --out "ready_import.csv"
courselink-helper option1 --root "~/Courses/CS101"

# Option 2: grading harness
courselink-helper option2
courselink-helper option2 --csv "grading/assignments/assignment1.csv"
courselink-helper option2 --csv "grading/assignments/assignment1.csv" --progress-out "my_progress.csv"
courselink-helper option2 --root "~/Courses/CS101"

Notes

  • When --csv is not provided, CSV selection starts at the current working directory by default.
  • The built-in picker shows only directories that contain at least one CSV somewhere below them, plus CSV files in the current directory.
  • fzf mode searches recursively across CSV paths under the active browse root.
  • fzf is optional and not a Python dependency; install separately if desired.
  • Progress files use __progress.csv suffix by default.
  • Output from option 1 uses __ready_to_import.csv suffix by default.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

courselink_grader-0.1.0.tar.gz (13.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

courselink_grader-0.1.0-py3-none-any.whl (12.4 kB view details)

Uploaded Python 3

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page