Bug 23398 - Exporting/Reimporting frameworks in XML format will give incomplete results
Summary: Exporting/Reimporting frameworks in XML format will give incomplete results
Status: Pushed to master
Alias: None
Product: Koha
Classification: Unclassified
Component: System Administration (show other bugs)
Version: master
Hardware: All All
: P5 - low critical (vote)
Assignee: Jonathan Druart
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks: 23892
  Show dependency treegraph
 
Reported: 2019-07-29 19:04 UTC by Katrin Fischer
Modified: 2019-11-08 12:56 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
19.11.00


Attachments
Bug 23398: Disable the XML import/export format for biblio framework (10.20 KB, patch)
2019-10-24 16:26 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 23398: Disable the XML import/export format for biblio framework (10.25 KB, patch)
2019-11-07 14:50 UTC, Martin Renvoize
Details | Diff | Splinter Review
Bug 23398: Disable the XML import/export format for biblio framework (10.36 KB, patch)
2019-11-08 07:40 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Katrin Fischer 2019-07-29 19:04:42 UTC
Michael Kuhn reported on the mailing list:

As usual when creating a new framework I did export the standard framework in XML format, created a new framework ABC and the imported the XML file into the new framework ABC.

I tried to do this in virgin installations of Koha 18.11.04 and Koha 19.05.00 but instead of importing all 345 MARC fields, only 102 were actually imported.


I've verified this on master with the same result:

- Pick any framwork, I used Kit
- Export it using the XML format
- Create a new framework, name it as you want
- Import using the downloaded XML file
- Compare both frameworks
- Verify that the number of fields is different
Comment 1 Jonathan Druart 2019-08-05 19:09:48 UTC
Is this a regression or it never worked?

Note: I exported the default framework, the import process is broken: 020 is the first non imported field and it is in the generated .xml file.

CSV is ok
Comment 2 Katrin Fischer 2019-08-06 21:14:12 UTC
I am not sure, we've always used the OpenDocument format, so I have never run into this so far.
Comment 3 Katrin Fischer 2019-10-21 06:07:40 UTC
Why does this not show up on the dashboard with the other criticals?
Comment 4 Jonathan Druart 2019-10-21 07:20:59 UTC
(In reply to Katrin Fischer from comment #3)
> Why does this not show up on the dashboard with the other criticals?

We display the bug reports created in the last 60 days if the status is NEW, ASSIGNED, In disussion, FQA or does not apply.
Comment 5 Katrin Fischer 2019-10-21 07:52:02 UTC
(In reply to Jonathan Druart from comment #4)
> (In reply to Katrin Fischer from comment #3)
> > Why does this not show up on the dashboard with the other criticals?
> 
> We display the bug reports created in the last 60 days if the status is NEW,
> ASSIGNED, In disussion, FQA or does not apply.

Didn't know about the last 60 days... guess the situation si worse than I thought it is!
Comment 6 Jonathan Druart 2019-10-24 16:26:16 UTC
Created attachment 94687 [details] [review]
Bug 23398: Disable the XML import/export format for biblio framework

It gives incomplete results and not sure it ever worked.
To prevent data loss it is better to remove this option.

Note that the code in C4/ImportExportFramework.pm is too complex to
attach with this patch to deletion of the code related to the XML
import/export. Safer to keep it for a separate bug report.

Test plan:
Import/export biblio frameworks and confirm that there is no more
reference to the xml format.
Comment 7 Martin Renvoize 2019-11-07 14:50:06 UTC
Created attachment 95161 [details] [review]
Bug 23398: Disable the XML import/export format for biblio framework

It gives incomplete results and not sure it ever worked.
To prevent data loss it is better to remove this option.

Note that the code in C4/ImportExportFramework.pm is too complex to
attach with this patch to deletion of the code related to the XML
import/export. Safer to keep it for a separate bug report.

Test plan:
Import/export biblio frameworks and confirm that there is no more
reference to the xml format.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 8 Martin Renvoize 2019-11-07 14:50:54 UTC
Code scans well and does what is expected. 

I agree to the pragmatic decision of just removing the option at this point too.

Signing off.
Comment 9 Marcel de Rooy 2019-11-08 07:40:15 UTC
Created attachment 95179 [details] [review]
Bug 23398: Disable the XML import/export format for biblio framework

It gives incomplete results and not sure it ever worked.
To prevent data loss it is better to remove this option.

Note that the code in C4/ImportExportFramework.pm is too complex to
attach with this patch to deletion of the code related to the XML
import/export. Safer to keep it for a separate bug report.

Test plan:
Import/export biblio frameworks and confirm that there is no more
reference to the xml format.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 10 Martin Renvoize 2019-11-08 12:56:51 UTC
Nice work!

Pushed to master for 19.11.00