pub fn apply_grade(state: &AppState, path: &str, grade: &str) -> Result<()>
Write a grade to the file, the in-memory map and the persisted cache. Only paths the last scan found are accepted.