Expand description
The files an exercise task’s specs reference.
An exercise service declares them, the same way an answer names its files: the host stores
specs as opaque blobs, so a declaration is the only way it can know that a stored file is still
in use. The private spec’s files are declared in the editor’s current-state message, and each
derived spec’s in the response of the endpoint that produced it.
The kinds are tracked apart because a derived spec can name a file the private spec never did:
a service may upload while deriving, through SpecRequest.upload_url, which is how tmc stores
the template students download.
Used only to keep crate::exercise_spec_uploads’ reaper off files that are still referenced.
Enums§
- Spec
Kind - Which of a task’s three specs a reference belongs to.
Functions§
- comma_
separated 🔒 - get_
by_ exercise_ task_ ids - What each task’s spec of the given kind declares, keyed by task. Tasks that declare nothing are absent from the map rather than present with an empty list.
- get_
for_ exercise_ task - What one of a task’s specs declares, in no particular order: the order of a spec’s files is the exercise service’s business and lives inside the spec.
- replace_
for_ exercise_ task - Replaces what one of a task’s specs declares with
file_upload_ids.