8 Commits

Author SHA1 Message Date
Zeyad Yasser
54c6a1d8c3 refactor: replace IsNotFound usages for errors.Is(err, &NotFoundError{}) 2023-02-09 16:02:40 +00:00
Michael Vogt
277eb06412 many: replace use of "sanity" with more inclusive naming
This commit replaces the use of "sanity" with more inclusive
naming.

When `sanity` is used in a more general sense either `validity`
or `quick` is used.
2022-03-14 18:22:34 +01:00
Samuele Pedroni
35c76d6f1a seed: ReadSystemEssentialAndBetterEarliestTime (#10005)
ReadSystemEssentialAndBetterEarliestTime retrieves in one go
information about the model and essential snaps of the given types
for the Core 20 recovery system seed specified by seedDir and label
(which cannot be empty).
It can operate even if current system time is unreliable by taking
a earliestTime lower bound for current time.
It returns as well an improved lower bound by considering appropriate
assertions in the seed.

* asserts: Batch.CommitToAndObserve

have a variant of CommitTo that supports a callback to consider each
assertion immediately after it has been added to the database, at
which point it also verified
2021-03-18 18:40:16 +01:00
Samuele Pedroni
74a1d5c3c4 rename var for clarity 2019-08-23 09:32:06 +02:00
Samuele Pedroni
f9f19ec9d2 make Precheck an option to CommitTo instead of a separate method
as discussed/suggested

clarify docs
2019-08-23 09:25:58 +02:00
Samuele Pedroni
4b584e9e29 improve doc comments 2019-08-19 17:00:19 +02:00
Samuele Pedroni
b73d89162d use clearer in context terminolgy: linerarized -> inPrereqOrder 2019-08-18 10:51:23 +02:00
Samuele Pedroni
a12ffaa007 move and generalise assertstate.Batch to asserts itself
next steps are updating places using Batch and changing assertsstate
2019-08-18 08:56:47 +02:00