-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem: fatal error when SIP is a BagIt bag #10
Comments
I guess making the CreateBagActivity noop when it receives a Bag won't hurt, but I was thinking to address this issue just with documentation. I see this template repository as an example never to be run as part of a real workflow. |
I tested https://github.com/LibraryOfCongress/bagit-python to see what it does when asked to bag a bag, and it just "double bags" the contents -- everything in the original bag (including manifests, metadata files, and the data directory) are put in a "data" directory and then it generates new manifests for everything. I don't know that I want to implement the same behaviour for the CreateBagActivity, but I think we should do better than the current error. Another option is just to return a better error message like 'create bag: /path/to/dir is already a bag" or something similar. |
I took the route of doing a rudimentary check to see if a directory already appears to be a Bag and, if so, return it's source path as the Bag path. PR for CR: artefactual-sdps/temporal-activities#43 |
New PR to update the preprocessing-base repo to use the updated activity: |
PR merged. |
I've merged a PR that updates the preprocessing-demo repo with this update as well (so when the demo test site is updated QA can be done). |
If the SIP delivered to Enduro is a BagIt bag the pre-processing workflow fails with a fatal error at the "CreateBagActivity":
To Reproduce
Steps to reproduce the behavior:
Expected behavior
In real world implementations of preprocessing the SIP delivered by Enduro will be modified before being bagged and sent back to Enduro in which case the bag will need to be updated or its contents "unbagged" to prevent errors validating the bag payload against its manifest.
If the "CreateBagActivity" receives a BagIt bag as input, it should return the path of the bag, without altering the bag. Preprocessing will then deliver the unaltered bag to Enduro for further processing.
Additional context
See artefactual-sdps/enduro#805 for more information about the exchange of bags between preprocessing and Enduro.
The text was updated successfully, but these errors were encountered: