From 2e285e469251125ee70bc4c3408dbbcad8701b2c Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Mon, 11 Oct 2021 11:01:38 -0700 Subject: fileset ingest: improve error handling --- python/sandcrawler/fileset_types.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'python/sandcrawler/fileset_types.py') diff --git a/python/sandcrawler/fileset_types.py b/python/sandcrawler/fileset_types.py index 51000d7..9fe8b0d 100644 --- a/python/sandcrawler/fileset_types.py +++ b/python/sandcrawler/fileset_types.py @@ -42,3 +42,21 @@ class ArchiveStrategyResult(BaseModel): ingest_strategy: str status: str manifest: List[FilesetManifestFile] + +class PlatformScopeError(Exception): + """ + For incidents where platform helper discovers that the fileset/dataset is + out-of-cope after already starting to process it. + + For example, attempting to ingest: + + - a 'latest version' record, when the platform has version-specific records + - a single file within a dataset for a platform which has file-level identifiers + """ + pass + +class PlatformRestrictedError(Exception): + """ + When datasets are not publicly available on a platform (yet) + """ + pass -- cgit v1.2.3