swh.vault.interface module¶
-
class
swh.vault.interface.
VaultInterface
(*args, **kwds)[source]¶ Bases:
typing_extensions.Protocol
Backend Interface for the Software Heritage vault.
-
fetch
(obj_type: str, obj_id: Union[str, bytes]) → Dict[str, Any][source]¶ Fetch information from a bundle
-
cook
(obj_type: str, obj_id: Union[str, bytes], email: Optional[str] = None) → Dict[str, Any][source]¶ Main entry point for cooking requests. This starts a cooking task if needed, and add the given e-mail to the notify list
-
set_progress
(obj_type: str, obj_id: Union[str, bytes], progress: str) → None[source]¶ Set the cooking progress of a bundle
-
set_status
(obj_type: str, obj_id: Union[str, bytes], status: str) → None[source]¶ Set the cooking status of a bundle
-
send_notif
(obj_type: str, obj_id: Union[str, bytes])[source]¶ Send all the e-mails in the notification list of a bundle
-