HomeSoftware Heritage

storage*: type origin_visit_get_latest endpoint result

Description

storage*: type origin_visit_get_latest endpoint result

The endpoint returns an optional OriginVisit object instead of a dict:

def origin_visit_get_latest(...) -> Optional[OriginVisit]

It also fixes the in-memory storage implementation which filtered data too
early. It only filtered on the latest origin visit status associated to the
origin visit. So depending on filters, this could have been wrong. It was not
much of a problem as there is no longer any direct clients of this api (they
are using [1] now).

[1] swh.storage.algos.origin.origin_get_latest_origin_visit_status function

Related to T645