One difference between a Lean mapping and the live schema, found by verifySchema.
- missingType (label : String) : SchemaIssue
- wrongKind (label expected actual : String) : SchemaIssue
- wrongSupertype (label expected : String) (actual : Option String) : SchemaIssue
- missingOwns (owner attr : String) : SchemaIssue
- wrongValueType (attr expected actual : String) : SchemaIssue
- missingRelates (relation role : String) : SchemaIssue
- missingPlays (player role : String) : SchemaIssue
Instances For
Equations
- TypeDB.instReprSchemaIssue = { reprPrec := TypeDB.instReprSchemaIssue.repr }
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
Equations
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.missingType a) (TypeDB.SchemaIssue.missingType b) = (a == b)
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.wrongKind a a_1 a_2) (TypeDB.SchemaIssue.wrongKind b b_1 b_2) = (a == b && (a_1 == b_1 && a_2 == b_2))
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.wrongSupertype a a_1 a_2) (TypeDB.SchemaIssue.wrongSupertype b b_1 b_2) = (a == b && (a_1 == b_1 && a_2 == b_2))
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.missingOwns a a_1) (TypeDB.SchemaIssue.missingOwns b b_1) = (a == b && a_1 == b_1)
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.wrongValueType a a_1 a_2) (TypeDB.SchemaIssue.wrongValueType b b_1 b_2) = (a == b && (a_1 == b_1 && a_2 == b_2))
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.missingRelates a a_1) (TypeDB.SchemaIssue.missingRelates b b_1) = (a == b && a_1 == b_1)
- TypeDB.instBEqSchemaIssue.beq (TypeDB.SchemaIssue.missingPlays a a_1) (TypeDB.SchemaIssue.missingPlays b b_1) = (a == b && a_1 == b_1)
- TypeDB.instBEqSchemaIssue.beq x✝¹ x✝ = false
Instances For
Equations
Equations
- One or more equations did not get rendered due to their size.
Everything that can go wrong talking to TypeDB.
- connection
(code message : String)
: TypeDBError
The server could not be reached, or refused the connection or credentials.
- server
(code message : String)
: TypeDBError
The server rejected a request;
codeis TypeDB's error code, e.g.TQL03. - conflict
(message : String)
: TypeDBError
A commit lost against a concurrent transaction; retrying may succeed.
- decode
(column expected got : String)
: TypeDBError
A column or document did not have the shape the decoder expects.
- schemaMismatch
(issues : List SchemaIssue)
: TypeDBError
The live schema differs from the Lean mappings.
- migration
(version : Nat)
(message : String)
: TypeDBError
A migration could not run;
versionnames the step. - io
(message : String)
: TypeDBError
An
IOerror raised inside a transaction body. - internal
(message : String)
: TypeDBError
A misuse of the library or a driver failure with no TypeDB code.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- TypeDB.instReprTypeDBError = { reprPrec := TypeDB.instReprTypeDBError.repr }
Equations
Equations
- (TypeDB.TypeDBError.conflict message).isConflict = true
- x✝.isConflict = false
Instances For
Classifies a driver error. Commit conflicts are storage errors STC2 ("isolation conflict"),
which the server may wrap in another error, so the whole message is searched.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- (TypeDB.TypeDBError.connection a a_1).toString = toString "connection error [" ++ toString a ++ toString "]: " ++ toString a_1
- (TypeDB.TypeDBError.server a a_1).toString = toString "server error [" ++ toString a ++ toString "]: " ++ toString a_1
- (TypeDB.TypeDBError.conflict a).toString = toString "commit conflict: " ++ toString a
- (TypeDB.TypeDBError.decode a a_1 a_2).toString = toString "cannot decode column '" ++ toString a ++ toString "': expected " ++ toString a_1 ++ toString ", got " ++ toString a_2
- (TypeDB.TypeDBError.schemaMismatch a).toString = "schema mismatch:\n" ++ "\n".intercalate (List.map (fun (x : TypeDB.SchemaIssue) => toString " - " ++ toString x) a)
- (TypeDB.TypeDBError.migration a a_1).toString = toString "migration " ++ toString a ++ toString ": " ++ toString a_1
- (TypeDB.TypeDBError.io a).toString = toString "IO error: " ++ toString a
- (TypeDB.TypeDBError.internal a).toString = toString "internal error: " ++ toString a
Instances For
Equations
- TypeDB.TypeDBError.instToString = { toString := TypeDB.TypeDBError.toString }
Maps the error of an EIO action.
Equations
- TypeDB.mapError f x = do let __do_lift ← liftM x.toBaseIO match __do_lift with | Except.ok a => pure a | Except.error e => throw (f e)
Instances For
IO actions run inside TypeDB code report their errors as TypeDBError.io.
Equations
- TypeDB.instMonadLiftIOEIOTypeDBError = { monadLift := fun {α : Type} (x : IO α) => IO.toEIO (fun (e : IO.Error) => TypeDB.TypeDBError.io (toString e)) x }
Runs a native call, classifying its error.