pub fn refuse_skipped_validation<'a>(
validate: Option<bool>,
collections: impl IntoIterator<Item = &'a str>,
) -> Option<ApiError>Expand description
The validate flag, which is atproto’s own name for the three stances.
The Lexicon specification names three: explicit, where every record must resolve to a known schema and satisfy it; optimistic, where a record is checked when a schema is at hand and stored faithfully when it is not; and skip. The parameter is a tri-state and each state is one of them.
Unset is optimistic, and it is the stance this server takes.
true is explicit and is honoured for the one request: a record in a
collection this server holds no lexicon for is refused rather than stored.
false skips the schema check, and this server honours it for a
collection it holds no lexicon for: there is no check to skip, and the
record is stored and reported unknown just as it is when the flag is
unset. A collection whose lexicon it holds is read by an index, a
clusterer and a canvas that rely on its shape, and a record stored past
its own schema is one no reader downstream can rely on. So false naming
one of those collections is refused rather than ignored, for the same
reason a swap field is: a request whose precondition this server will
not meet should say so.