Repository navigation
v0.6.0
Trace has a Year 9 preset that leaves out functions and their variables, and every trace sheet names its preset. Pseudocode works out which language it was given, Worksheet sets Boolean and truth-table questions that read like a textbook, and Marks analyses a whole year group in under a second. Staffroom keeps working when its settings folder cannot be written.
Update: quit Staffroom, run uv tool upgrade staffroom in Terminal, and open it again (Updating covers a copy installed from a release tag). New to Staffroom? Start with Install.
For contributors: the full list (12 changes)
Added
- Trace has a Preset dropdown with Full trace (the default, as before) and Year 9: the Year 9 preset turns on the new Top-level variables only option (
--top-level-onlyon the CLI), which leaves out the lines run inside functions and their locals, so the sheet has no Scope column and only the program's own variables. Every trace sheet now names its preset in the header (Full trace, Year 9 or Custom) so a teacher can tell which one they handed out. Presets for an options form are part of the shared panel vocabulary (OptionsForm.presets,core.panel.preset) and widget kit, so any tool can offer them. - The launcher shows the running version: the sidebar header reads
v0.5.0 · 9 tools, and Settings › Updates saysRunning Staffroom 0.5.0, adding the branch and short commit off a release tag (0.5.0 (dev, a1b2c3d)).packaging/make_launcher.pywrites the package version into the bundle'sCFBundleShortVersionStringandCFBundleVersion, so Finder's Get Info matches afterjust install.
Changed
classroompromote compares the copy with the original and with the latest promoted version before writing: an unchanged copy makes no new file and the message saysAlready promoted as year9_v2.py(or that it matches the original). The CLI exits 0 and prints no path when nothing was written.quiznames any taught-log column other thandateandtopicin the run log (ignored column 'room' — the log is date and topic only), by header only; the column's contents are never read or shown.
Fixed
quizreads the taught log throughcore.csvio.read_tablelike every other table, so an identifier column (name,class, …) is dropped before the tool sees it, with the usual dropped-column warning and a run-log line by header only. It used to parse the file as raw text, bypassing the privacy filter. A new boundary test fails if any tool reads a.csv/.xlsxwithoutcore.csvio(rawopen/read_textof a table path,csv.reader,openpyxl.load_workbook, or csvio's unfilteredread_csv/read_xlsx).- The launcher opens when the config home cannot be written. It used to die in
LibraryDBwithsqlite3.OperationalError: unable to open database file. The library now opens the last index read-only, or an empty in-memory database when there is none, and says Resource Library unavailable: cannot write once in the log, in the Resources sidebar and header, and instaff library status(exit 0). Re-index is disabled,staff library indexandsearchexit 1 with that line, and every tool still runs. The window's own settings (last tool, sidebar mode, theme) last for the session with one warning instead of a traceback per click. staffno longer dies with aPermissionErrortraceback when the config home (~/.config/staffroom/orSTAFFROOM_HOME) cannot be written.setup_loggingused to createlogs/and open the log file with no fallback, before any command ran; it now carries on with stderr alone and prints one warning line naming the file it could not open. The launcher takes the same path, so its startup gets the same fallback.worksheetrefuses a count outside 1–60 with one sentence ("Questions must be between 1 and 60 (you asked for 0).") instead of writing an empty sheet and key; the CLI and the panel share the limits. Boolean simplification questions are now built from textbook forms only (absorption, the distributive pair, the redundancy formA AND (NOT A OR B), De Morgan over two literals) within a size budget per difficulty, so a hard three-step question reads(A OR (A AND C)) AND NOT (A AND NOT B)rather than a form nested three deep; each key practises more than one law and a sheet never repeats a question. GCSE truth tables get one shape per difficulty (one gate, two gates, three gates or aNOTover a bracket), so medium and hard sheets no longer look the same. Keys stay reproducible from the printed seed.staff usagenow counts CLI runs as well as launcher runs: everystaff <tool> <command>that finishes without aToolErroris recorded by the one wrapper incli.py, so no tool needs its own call. The total stays one number per tool, with the launcher's and the CLI's shares shown beside it; older files (launcher-only) need no migration. Nothing is recorded when the config isread_onlyor the home folder cannot be written, and a failed write never fails the command.- Pseudocode works out the input language from the code itself when
--fromis not given, instead of calling every non-.pyfile OCR ERL:defand:blocks mean Python,endif/next/thenmean OCR,←/OUTPUT/USERINPUTmean AQA, with the file name as the tie-breaker. The log and summary say what was decided ("Treated input as AQA pseudocode (guessed from the code)"); code with nothing to go on, or that already looks like the target, stops with a message naming the--fromto pass. The panel's single Direction is now From (defaultguess) and To. marksgrades a whole cohort in well under a second:discrimination()computed every script's total once per comparison, which took a minute for 3,000 rows. Fixed quietly in 0.4.0; now measured and guarded by tests (3,000 × 30 marks analysed in 0.15 s).- The library's file counts agree everywhere. The sidebar said "563 files" and the Resources header "587 files indexed" because one left out hidden cruft and the other did not; a pending exclusion widened the gap. Both now show the one line
LibraryService.counts()produces,563 files (24 hidden) · 3 name only, with the hidden shown as a subset instead of silently dropped, andstaff library statusand the index summary print the same tally in long form (587 indexed: 563 shown, 24 hidden, 2 cloud-only, 3 name only). The definition is in the launcher guide.