Checks.Integrity_checks
module XKey : Pack_key.S
module X :
Brassaia_eio_pack_io.Import.Brassaia.Backend.S
with type Commit.key = XKey.t
and type Node.key = XKey.t
and type Schema.Hash.t = XKey.hash
module Index : Pack_index.S
val check_always :
?ppf:Stdlib.Format.formatter ->
auto_repair:bool ->
check:
(kind:[> `Commit | `Contents | `Node ] ->
offset:Import.int63 ->
length:int ->
Index.key ->
(unit, [< `Absent_value | `Wrong_hash ]) Stdlib.result) ->
Index.t ->
([> `Fixed of int | `No_error ],
[> `Cannot_fix of string | `Corrupted of int ])
Stdlib.result
val check_minimal :
?ppf:Stdlib.Format.formatter ->
pred:
(X.Node.value ->
(Brassaia_eio_pack_io.Import.Path.step option
* [< `Contents of XKey.t | `Inode of XKey.t | `Node of XKey.t ])
list) ->
iter:
(contents:(XKey.hash Pack_key.t -> unit) ->
node:(XKey.t -> unit) ->
pred_node:
(X.Repo.t -> XKey.t -> [> `Contents of XKey.t | `Node of XKey.t ] list) ->
pred_commit:(X.Repo.t -> XKey.t -> [> `Node of XKey.t ] list) ->
X.Repo.t ->
unit) ->
check:
(offset:Import.int63 ->
length:int ->
XKey.hash ->
(unit, [< `Absent_value | `Wrong_hash ]) Stdlib.result) ->
recompute_hash:(X.Node.value -> XKey.hash) ->
X.Repo.t ->
([> `No_error ], [> `Cannot_fix of string ]) Stdlib.result
val check_inodes :
?ppf:Stdlib.Format.formatter ->
iter:
(pred_node:
(X.Repo.t ->
XKey.t ->
[> `Contents of XKey.t | `Node of XKey.t ] as 'a list) ->
node:(XKey.t -> unit) ->
commit:(XKey.t -> unit) ->
X.Repo.t ->
unit) ->
pred:(X.Repo.t -> XKey.t -> 'a list) ->
check:(XKey.t -> (unit, string) Stdlib.result) ->
X.Repo.t ->
([> `No_error ], [> `Cannot_fix of string ]) Stdlib.result