<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>507414</bug_id>
          
          <creation_ts>2025-07-23 21:30:07 +0000</creation_ts>
          <short_desc>Regression: Error importing ISO20022 XML into Skrooge</short_desc>
          <delta_ts>2025-07-25 20:20:44 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>skrooge</product>
          <component>general</component>
          <version>Trunk from git</version>
          <rep_platform>Other</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>25.1.0</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Matija Šuklje">matija</reporter>
          <assigned_to name="Stephane MANKOWSKI">stephane</assigned_to>
          
          
          <cf_commitlink>https://invent.kde.org/office/skrooge/-/commit/ee47b689445caa982bc048ac0278f68c01db928b</cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2442588</commentid>
    <comment_count>0</comment_count>
    <who name="Matija Šuklje">matija</who>
    <bug_when>2025-07-23 21:30:07 +0000</bug_when>
    <thetext>SUMMARY

When I import an ISO20022 XML, Skrooge does not import it, but reports an error.

This seems to be a regression, because to double-check I tried to import an XML file that I have successfully imported before and it threw the same error.

STEPS TO REPRODUCE
1. get ISO20022 XML monthly bank statement from bank
2. File ↦ Import ↦ Import and select said XML file

OBSERVED RESULT

Skrooge throws an error:

```
[ERR-5]: Import of file named &apos;file:///home/hook/Dokumenti/Denar/Bančni izpiski/2024/ISO 20022 (TRR EUR @ DBS) – 2024-07-01.xml&apos; failed
[ERR-5]: The conversion in xml of &apos;file:///home/hook/Dokumenti/Denar/Bančni izpiski/2024/ISO 20022 (TRR EUR @ DBS) – 2024-07-01.xml&apos; failed
[ERR-5]: The execution of &apos;sed -E &apos;s/ xmlns(:[a-zA-Z0-9]+)?=&quot;[^&quot;]+&quot;//g&apos; &quot;/home/hook/Dokumenti/Denar/Bančni izpiski/2024/ISO 20022 (TRR EUR @ DBS) – 2024-07-01.xml&quot; &gt; &quot;/tmp/{8fe5989b-108d-4fc2-a469-1671083741a0}.xml&quot;;saxonb-xslt -xsl:&quot;/usr/share/skrooge/ISO20022.xslt&quot; -s:&quot;/tmp/{8fe5989b-108d-4fc2-a469-1671083741a0}.xml&quot; -o:&quot;/tmp/{8fe5989b-108d-4fc2-a469-1671083741a0}.xml&quot;&apos; failed
```

EXPECTED RESULT

Skrooge imports the transactions without error (as it did before).


SOFTWARE/OS VERSIONS
actual Skrooge version: 25.4.0
Qt Version: Operating System: EndeavourOS 
KDE Plasma Version: 6.4.3
KDE Frameworks Version: 6.16.0
Qt Version: 6.9.1

ADDITIONAL INFORMATION</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2442591</commentid>
    <comment_count>1</comment_count>
    <who name="Matija Šuklje">matija</who>
    <bug_when>2025-07-23 21:45:07 +0000</bug_when>
    <thetext>Upon further digging, I suspect the culprit is that I don’t seem to have `saxonb-xsl` installed on my machine. It seems this dependency was introduced a few months ago during the Qt6 port, specifically here:

https://invent.kde.org/office/skrooge/-/commit/44621f8b8efee01380df46afa939080be724d7d1#6005aaa4fbe3fa54ed3d69b67fcbeec0776d092f_94_104</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2442798</commentid>
    <comment_count>2</comment_count>
    <who name="Stephane MANKOWSKI">stephane</who>
    <bug_when>2025-07-24 19:49:50 +0000</bug_when>
    <thetext>Git commit a6b40b0d2c33f2fe344b7cf10169f06934723078 by Stéphane MANKOWSKI.
Committed on 24/07/2025 at 19:49.
Pushed by smankowski into branch &apos;master&apos;.

Regression: Error importing ISO20022 XML into Skrooge

M  +2    -1    CHANGELOG
M  +11   -3    plugins/import/skrooge_import_xml/skgimportpluginxml.cpp

https://invent.kde.org/office/skrooge/-/commit/a6b40b0d2c33f2fe344b7cf10169f06934723078</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2442808</commentid>
    <comment_count>3</comment_count>
    <who name="Matija Šuklje">matija</who>
    <bug_when>2025-07-24 22:29:45 +0000</bug_when>
    <thetext>Stéphane, thanks for working on this so fast.

It seems like the command is not always called `saxonb-xslt` – e.g. on Arch(-based distros), it is only available in the user-contributed AUR and the command is called `saxon-xslt` (and currently broken, but that’s not Skrooge’s concern).

Would it be possible to rely on a more commonly packaged XSLT processor instead? Or be able to use either of the existing options?

According to https://en.wikipedia.org/wiki/Saxon_XSLT there are also LibXML/LibXSLT and Apache Xalan.

If a quick search on https://repology.org/ is worth anything, it seems Xalan is slightly more commonly packaged than Saxon, and LibXSLT is much more widely distributed then both.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2443006</commentid>
    <comment_count>4</comment_count>
    <who name="Stephane MANKOWSKI">stephane</who>
    <bug_when>2025-07-25 20:20:29 +0000</bug_when>
    <thetext>Hi,

XALAN doesn&apos;t support xslt 2.0, only 1.0 is supported.
That&apos;s why I selected saxonb.
I will do a modification to search saxonb-xslt or saxon-xslt.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2443007</commentid>
    <comment_count>5</comment_count>
    <who name="Stephane MANKOWSKI">stephane</who>
    <bug_when>2025-07-25 20:20:44 +0000</bug_when>
    <thetext>Git commit ee47b689445caa982bc048ac0278f68c01db928b by Stéphane MANKOWSKI.
Committed on 25/07/2025 at 20:19.
Pushed by smankowski into branch &apos;master&apos;.

Regression: Error importing ISO20022 XML into Skrooge

M  +11   -4    plugins/import/skrooge_import_xml/skgimportpluginxml.cpp

https://invent.kde.org/office/skrooge/-/commit/ee47b689445caa982bc048ac0278f68c01db928b</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>