https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35104
--- Comment #67 from Martin Renvoize (ashimema) <[email protected]> --- Created attachment 193997 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=193997&action=edit Bug 35104: Strip non-XML characters gracefully and notify user Instead of always throwing when MARCXML contains invalid characters, attempt recovery via StripNonXmlChars first. If stripping produces a parseable record, save the clean version and set stripped_nonxml on the object; only throw Koha::Exceptions::Metadata::Invalid when the record is truly unrecoverable. Propagate the strip notification through ModBiblioMarc -> ModBiblio / AddBiblio via an optional warnings arrayref in $options. Entry points (addbiblio.pl, merge.pl) collect warnings and display a prominent alert asking the user to review the saved record. Update unit tests: replace the embedded-ESC 'Invalid MARCXML handling' subtest with a chr(31)-based 'MARCXML with strippable non-XML characters' subtest and add a stripped_nonxml=undef assertion for clean records. Sponsored-by: OpenFifth -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
