Skip to main content

Module world

Module world 

Source
Expand description

The simulated Sisu and Suotar world: entities, the per-submission send and importer state, and the per-request working set the endpoints resolve over.

Plain values only, so the resolution logic stays a pure function over an in-memory slice.

Re-exports§

pub use super::wire::CreditRange;
pub use super::wire::DatePeriod;
pub use super::wire::LocalizedName;

Structs§

CourseBehaviour
Grade
GradeScale
MissedFault
MockAttainment
MockCourseUnit
MockEnrolment
MockPerson
MockRealisation
MockStudyRight
MockSubmission
One of Suotar’s entries rows: a completion written by an import, with what became of its Sisu send and what the importer has seen of it since.
PersonBehaviour
RecordedCall
One entry of the mock’s own call log: unscrubbed fake data, capped, never fed to the audited tables.
RecordedFaults
RecordedItem
SuotarCourse
WorkingSet
The slice of the world one request needs, read once and written back once.
WorldDefaults
Every field defaults, so a partial defaults push cannot install an empty accepted token and 401 the whole suite.

Enums§

AttainmentLevel
Which of Sisu’s two attainments a submission produces.
AttainmentState
Misregistered stands for Sisu’s separate misregistration flag, which the wire never shows: such an attainment reads as ATTAINED where it is listed at all, and resolve leaves it out.
EnrolmentState
ImporterVisibility
What the importer’s copy of Sisu holds for a submission. Only a control transition changes it.
RealisationKind
Which audience a fixture realisation serves; only picks the default ids. The wire’s kind comes from the enrolment’s study right id instead.
SendState
Suotar’s entries.sendState.
WorldWrite
One change the resolution logic wants persisted, one Redis command each.

Constants§

PENDING_WINDOW_HOURS
How long an unconfirmed send stays submissionPending before verify calls it notRegistered.
REFUSED_COURSE_CODES
Elements of AI and Building AI, which Suotar refuses whatever its course table says.

Functions§

default_grade_scales
person_course_key

Type Aliases§

CourseCode
StudentNumber