Skip to contentSkip to conversation

glib-networking: Fix ptest failures with openssl backend

PATCH Superseded Khem Raj 3 participants 5 messages Dec 22, 2023 – Jan 9, 2024

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/1 glib-networking: Fix ptest failures with openssl backend

---
 ...Disable-test_unclean_close_by_server.patch | 42 +++++++++++++++++++
 .../glib-networking/glib-networking_2.78.0.bb |  5 ++-
 2 files changed, 45 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-core/glib-networking/glib-networking/0001-tests-Disable-test_unclean_close_by_server.patch
meta/recipes-core/glib-networking/glib-networking/0001-tests-Disable-test_unclean_close_by_server.patch new file +42 -0
new file mode 100644
index 00000000000..44e92f52001
@@ -0,0 +1,42 @@
+From 378bb3b0bf001e66a89d100ba12ac183e8375c36 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 22 Dec 2023 09:46:36 -0800
+Subject: [PATCH] tests: Disable test_unclean_close_by_server
+
+This test does not work reliably when openSSL support is enabled. This
+is not default in OE therefore the ptest failure is not seen on AB
+testing
+
+Fixes
+
+not ok /tls/openssl/connection/unclean-close-by-server - GLib-Net:ERROR:../tls/tests/connection.c:2374:test_unclean_close_by_server: assertion failed (test->read_error == (g-tls-error-quark, 6)): Error reading data from TLS socket: error:00000005:lib(0)::reason(5) (g-tls-error-quark, 1)
+Bail out!
+stderr:
+**
+GLib-Net:ERROR:../tls/tests/connection.c:2374:test_unclean_close_by_server: assertion failed (test->read_error == (g-tls-error-quark, 6)): Error reading data from TLS socket: error:00000005:lib(0)::reason(5) (g-tls-error-quark, 1)
+
+Issue is already reported upstream [1]
+
+[1] https://gitlab.gnome.org/GNOME/glib-networking/-/issues/219
+Upstream-Status: Inappropriate [ Disabled test as a workaround until fixed ]
+Signed-off-by: Khem Raj <[email protected]>
+---
+ tls/tests/connection.c | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/tls/tests/connection.c b/tls/tests/connection.c
+index 62a7fbb..cc99645 100644
+--- a/tls/tests/connection.c
++++ b/tls/tests/connection.c
+@@ -3462,8 +3462,6 @@ main (int   argc,
+               setup_connection, test_simultaneous_sync_rehandshake, teardown_connection);
+   g_test_add ("/tls/" BACKEND "/connection/close-immediately", TestConnection, NULL,
+               setup_connection, test_close_immediately, teardown_connection);
+-  g_test_add ("/tls/" BACKEND "/connection/unclean-close-by-server", TestConnection, NULL,
+-              setup_connection, test_unclean_close_by_server, teardown_connection);
+   g_test_add ("/tls/" BACKEND "/connection/async-implicit-handshake", TestConnection, NULL,
+               setup_connection, test_async_implicit_handshake, teardown_connection);
+   g_test_add ("/tls/" BACKEND "/connection/output-stream-close", TestConnection, NULL,
+-- 
+2.43.0
+
meta/recipes-core/glib-networking/glib-networking_2.78.0.bb +3 -2
index 68f9a2ed783..e360e59b532 100644
@@ -30,8 +30,9 @@ PACKAGECONFIG[gnomeproxy] = "-Dgnome_proxy=enabled,-Dgnome_proxy=disabled,gsetti
 inherit gnomebase gettext upstream-version-is-even gio-module-cache ptest-gnome
 
 SRC_URI += "file://run-ptest"
-SRC_URI += "file://eagain.patch"
-
+SRC_URI += "file://eagain.patch \
+            file://0001-tests-Disable-test_unclean_close_by_server.patch \
+            "
 FILES:${PN} += "\
                 ${libdir}/gio/modules/libgio*.so \
                 ${datadir}/dbus-1/services/ \
Signature · 1 line
2.43.0
#1 lore raw

Patchtest results for [PATCH] glib-networking: Fix ptest failures with openssl backend

Thank you for your submission. Patchtest identified one or more issues with the patch. Please see the log below for more information:

---
Testing patch /home/patchtest/share/mboxes/glib-networking-Fix-ptest-failures-with-openssl-backend.patch

FAIL: test commit message presence: Please include a commit message on your patch explaining the change (test_mbox.TestMbox.test_commit_message_presence)

PASS: pretest src uri left files (test_metadata.TestMetadata.pretest_src_uri_left_files)
PASS: test CVE tag format (test_patch.TestPatch.test_cve_tag_format)
PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test Signed-off-by presence (test_patch.TestPatch.test_signed_off_by_presence)
PASS: test Upstream-Status presence (test_patch.TestPatch.test_upstream_status_presence_format)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test lic files chksum modified not mentioned (test_metadata.TestMetadata.test_lic_files_chksum_modified_not_mentioned)
PASS: test max line length (test_metadata.TestMetadata.test_max_line_length)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test src uri left files (test_metadata.TestMetadata.test_src_uri_left_files)

SKIP: pretest pylint: No python related patches, skipping test (test_python_pylint.PyLint.pretest_pylint)
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test lic files chksum presence: No added recipes, skipping test (test_metadata.TestMetadata.test_lic_files_chksum_presence)
SKIP: test license presence: No added recipes, skipping test (test_metadata.TestMetadata.test_license_presence)
SKIP: test pylint: No python related patches, skipping test (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)
SKIP: test summary presence: No added recipes, skipping test (test_metadata.TestMetadata.test_summary_presence)
SKIP: test target mailing list: Series merged, no reason to check other mailing lists (test_mbox.TestMbox.test_target_mailing_list)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this email with an explanation of why the patch should be accepted. If you believe these results are due to an error in patchtest, please submit a bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category under 'Yocto Project Subprojects'). For more information on specific failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank you!

#2 lore raw
In reply to Khem Raj

meta/recipes-core/glib-networking/glib-networking_2.78.0.bb PACKAGECONFIG[gnomeproxy] = "-Dgnome_proxy=enabled,-Dgnome_proxy=disabled,gsetti · line 34

Quoted 2 lines · Khem Raj via lists.openembedded.org
meta/recipes-core/glib-networking/glib-networking_2.78.0.bb +2 -0
+SRC_URI += "file://eagain.patch \
+            file://0001-tests-Disable-test_unclean_close_by_server.patch \

As this only affects builds with openssl, should we apply the patch in on openssl builds?

Ross

author
#3 lore raw
Quoted 7 lines · Ross Burton

meta/recipes-core/glib-networking/glib-networking_2.78.0.bb PACKAGECONFIG[gnomeproxy] = "-Dgnome_proxy=enabled,-Dgnome_proxy=disabled,gsetti · line 34

Quoted 2 lines · Khem Raj via lists.openembedded.org
meta/recipes-core/glib-networking/glib-networking_2.78.0.bb +2 -0
+SRC_URI += "file://eagain.patch \
+            file://0001-tests-Disable-test_unclean_close_by_server.patch \

As this only affects builds with openssl, should we apply the patch in on openssl builds?

is it enabled to run when using other backends ?

Quoted 2 lines

Ross

#4 lore raw
Quoted 11 lines · Khem Raj
Quoted 7 lines · Ross Burton

meta/recipes-core/glib-networking/glib-networking_2.78.0.bb PACKAGECONFIG[gnomeproxy] = "-Dgnome_proxy=enabled,-Dgnome_proxy=disabled,gsetti · line 34

Quoted 2 lines · Khem Raj via lists.openembedded.org
meta/recipes-core/glib-networking/glib-networking_2.78.0.bb +2 -0
+SRC_URI += "file://eagain.patch \
+            file://0001-tests-Disable-test_unclean_close_by_server.patch \

As this only affects builds with openssl, should we apply the patch in on openssl builds?

is it enabled to run when using other backends ?

That test doesn’t appear to be guarded to only run on openssl, so it passes with gnutls.

FWIW, it’s recommended to use gnutls unless you have incredibly good reasons, the openssl backend _is_ broken.

Ross