[Maria-discuss] Incorrectly formatted XML files in mariadb-server sources
Hi, Fedora's rpminspect tool reports [1] some incorrectly formatted XMLs (most of them used for testsuite) within mariadb source files, namely they are: mysql-test/plugin/sphinx/sphinx/testdata.xml - undefined namespace mysql-test/std_data/loadxml.dat - different parser errors, seems to me like it is ill formed on purpose of the test mysql-test/plugin/connect/connect/std_data/nocs.xml - not proper utf-8 encoding mysql-test/std_data/loaddata/mdev9874.xml - not proper utf-8 encoding sql/share/mariadb/charsets/Index.xml - redefined attribute mysql-test/std_data/ldml/Index.xml - redefined attribute It does not seem (to me) that the ill-formatting breaks anything, and that in some cases it is desired. Specifically the loadxml.dat XML, where the test case counts with the form as it is, and Index.xml files, where modification to the XML format could change the meaning of the file. In other cases, it seems (to me) that the correction of the XMLs to a valid format could be possible. These are specifically the XMLs with encoding issues, where it should be sufficient to specify a used charset (ISO-8859-1 in both cases). This is also the case with the undefined namespace in testdata.xml, whose definition should be also possible. Would the correct approach to this issue be to suppress the rpminspect warnings, or should the specified XML files be modified to a valid XML form? Thanks for your opinions in advance. [1] https://osci-jenkins-1.ci.fedoraproject.org/job/fedora-ci/job/rpminspect-pip... Zuzana Miklánková Associate Software Engineer Red Hat <https://www.redhat.com> <https://www.redhat.com>
Hi, Zuzana! I'd suggest to suppress all rpminspect warnings in the test files. Sometimes files may be ill-formed on purpose, sometimes not. But they're just for testing, so it just not worth the time and efforts to fix them. Index.xml is rather unfortunate, thought, ideally it should be a valid XML. But it'll need some work, in particular, we'll need to change the parser to read flags differently. Feel free to report a bug about it. Preferrably with some links to support your point that the Index.xml is ill-formed. On Oct 19, Zuzana Miklankova wrote:
Hi,
Fedora's rpminspect tool reports [1] some incorrectly formatted XMLs (most of them used for testsuite) within mariadb source files, namely they are:
mysql-test/plugin/sphinx/sphinx/testdata.xml - undefined namespace mysql-test/std_data/loadxml.dat - different parser errors, seems to me like it is ill formed on purpose of the test mysql-test/plugin/connect/connect/std_data/nocs.xml - not proper utf-8 encoding mysql-test/std_data/loaddata/mdev9874.xml - not proper utf-8 encoding sql/share/mariadb/charsets/Index.xml - redefined attribute mysql-test/std_data/ldml/Index.xml - redefined attribute
It does not seem (to me) that the ill-formatting breaks anything, and that in some cases it is desired. Specifically the loadxml.dat XML, where the test case counts with the form as it is, and Index.xml files, where modification to the XML format could change the meaning of the file.
In other cases, it seems (to me) that the correction of the XMLs to a valid format could be possible. These are specifically the XMLs with encoding issues, where it should be sufficient to specify a used charset (ISO-8859-1 in both cases). This is also the case with the undefined namespace in testdata.xml, whose definition should be also possible.
Would the correct approach to this issue be to suppress the rpminspect warnings, or should the specified XML files be modified to a valid XML form?
Thanks for your opinions in advance.
Regards, Sergei VP of MariaDB Server Engineering and security@mariadb.org
Hi Sergei, Thank you for responding! I have created the bug, as you suggested (MDEV-26905 <https://jira.mariadb.org/browse/MDEV-26905>). I will also try to suppress the other warnings. BR, Zuzana On Sun, Oct 24, 2021 at 10:22 PM Sergei Golubchik <serg@mariadb.org> wrote:
Hi, Zuzana!
I'd suggest to suppress all rpminspect warnings in the test files. Sometimes files may be ill-formed on purpose, sometimes not. But they're just for testing, so it just not worth the time and efforts to fix them.
Index.xml is rather unfortunate, thought, ideally it should be a valid XML. But it'll need some work, in particular, we'll need to change the parser to read flags differently.
Feel free to report a bug about it. Preferrably with some links to support your point that the Index.xml is ill-formed.
Hi,
Fedora's rpminspect tool reports [1] some incorrectly formatted XMLs (most of them used for testsuite) within mariadb source files, namely they are:
mysql-test/plugin/sphinx/sphinx/testdata.xml - undefined namespace mysql-test/std_data/loadxml.dat - different parser errors, seems to me like it is ill formed on
On Oct 19, Zuzana Miklankova wrote: purpose
of the test mysql-test/plugin/connect/connect/std_data/nocs.xml - not proper utf-8 encoding mysql-test/std_data/loaddata/mdev9874.xml - not proper utf-8 encoding sql/share/mariadb/charsets/Index.xml - redefined attribute mysql-test/std_data/ldml/Index.xml - redefined attribute
It does not seem (to me) that the ill-formatting breaks anything, and that in some cases it is desired. Specifically the loadxml.dat XML, where the test case counts with the form as it is, and Index.xml files, where modification to the XML format could change the meaning of the file.
In other cases, it seems (to me) that the correction of the XMLs to a valid format could be possible. These are specifically the XMLs with encoding issues, where it should be sufficient to specify a used charset (ISO-8859-1 in both cases). This is also the case with the undefined namespace in testdata.xml, whose definition should be also possible.
Would the correct approach to this issue be to suppress the rpminspect warnings, or should the specified XML files be modified to a valid XML form?
Thanks for your opinions in advance.
Regards, Sergei VP of MariaDB Server Engineering and security@mariadb.org
participants (2)
-
Sergei Golubchik
-
Zuzana Miklankova