-
Notifications
You must be signed in to change notification settings - Fork 1
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: Non-default processing config is not copied over to the transfer directory for zipped (based) transfers e.g. zipped bag #771
Comments
Having chatted with @ross-spencer and looked into this some more, it seems the problem is not where I thought it was. Since the copy command mentioned above uses the It seems this only happens with zipfile based transfers (bagged and otherwise). For non zipped transfers, the temporary directory into which the the correct processing config was copied, is copied and becomes the transfer directory. However for zipped transfers, the zipfile is extracted and the extract directory is used as the transfer directory - so there's no processing config in there. So when we get to the "copy default processing" step in the workflow, there is no processing config in the transfer and the default gets used. I'm thinking the zip extraction step needs to ensure the processing config gets copied across. |
I'm a little stuck on how to do this. I found We could try pulling it out of the tmp directory at the extraction stage but that seems maybe a little messy (does MCP Client otherwise deal with the tmp directory?) and I'm not sure about the lifetime of the tmp directory. Another possibility would be to have MCP Server push the config file into the zip, but that doesn't seem ideal either. Taking a step back to have a little think about this - thoughts welcome :) |
I think it might work if I pre-create the directory into which the file will be unzipped during |
I think this involves:
(edit: Just realised the second of those two is not needed :) |
This is good analysis @helenst, I see |
@replaceafill could you get a size on this please? |
Okay, so we lost track of this during the I'll place this in For testing, I might suggest this be tested against:
|
I can confirm that the two scenarios in @ross-spencer's last comment now work:
It would be good to also test in a way more in-line with how @helenst was doing it - e.g. as an API call. Tested on qa/1.x on Bionic. |
Here's an example for you @sallain I have these at the ready today for the other pieces:
This does rely on the new sample data but you can see how the path is setup relative to You can do this remotely of course, so from your own Linux box you might need: Note there's a PR to discuss Tuesday for the Also, just remove |
I've initiated some tests using the API and can confirm that this works - I can define a custom config and apply it to a zipped bag transfer. I was unable to try a zipped directory transfer as there seems to be a bug to prevent users from defining |
@replaceafill maybe you can have a look at the problem with zipped directory transfers noted above? |
Arrrghhhhhh I had a typo in my sampledata path - I can, in fact, start a zipped directory transfer by doing the following:
It follows my custom processing config. So... that's good! This is fixed! |
I've added tests for the following: * Transfer name with diacritics archivematica/Issues#1051 * Transfer has filenames with diacritics and a metadata.csv archivematica/Issues#1073 * PREMIS event import archivematica/Issues#710 * identifiers.json import archivematica/Issues#963 * Directory-level AIP metadata is indexed archivematica/Issues#888 * Directories not greyed out if there are still files that can be arranged archivematica/Issues#822 * Reingest encrypted AIP archivematica/Issues#820 * Zipped bag containing custom processing config archivematica/Issues#771 * Download AIP METS file archivematica/Issues#644 * Descriptive metadata added through GUI is indexed for searching archivematica/Issues#547 * Processing storage usage screen update archivematica/Issues#312 * User with accented characters archivematica/Issues#261 * Change filenames archivematica/Issues#230 * Start SIP using tags archivematica/Issues#1052 * Zipped directory transfers archivematica/Issues#682
Expected behaviour
When a transfer is initiated using a non-default processing config, (either using `window.processing_config = 'my_config' or initiating via the API) the setup of that configuration should be used to select options at decision points in the workflow.
Current behaviour
When a non-default processing config is selected, the workflow still appears to use the default one. I think this is because, whereas MCP Server copies the correct config into the working directory to start with (
package._copy_processing_config
) there is an early step in the workflow which overwrites it withdefaultProcessingMCP.xml
.The filename that is copied over in the workflow is hardcoded in
workflow.json
currently. This could be fixed using a substitution variable (i.e.%processingConfig%processingMCP.xml
) which could be supplied with the correct config value.Steps to reproduce
Run a transfer using the builtin
automated
config (or create a custom one). The decisions in the workflow will still correspond to the default workflow. (e.g. with automated, questions will still be asked)Your environment (version of Archivematica, OS version, etc)
qa/1.x branch
Additional (RS: 2010-11-06)
You can use the current sample-data layout in Docker to test this by:
wellcome
.httpie
run the following command:For Artefactual use:
Please make sure these steps are taken before moving this issue from Review to Verified in Waffle:
The text was updated successfully, but these errors were encountered: