Author: jim
Date: Tue Jun 2 15:50:29 2026
New Revision: 1934891
Log:
test/h2: ignore AH02430 for the whole TestRfc9113 class
test_h2_203_02 intentionally triggers AH02430 (illegal response header
char). Over HTTP/2 the error is logged late during stream teardown and
can produce several lines, so the per-case ignore_recent() raced them
and they leaked into a later test's check_error_log(). Move the ignore
to an autouse class fixture (as conftest.py does for AH10400/AH00045)
and add HttpdErrorLog.remove_ignored_lognos() to restore on teardown.
Modified:
httpd/httpd/trunk/test/modules/http2/test_203_rfc9113.py
httpd/httpd/trunk/test/pyhttpd/log.py
Modified: httpd/httpd/trunk/test/modules/http2/test_203_rfc9113.py
==============================================================================
--- httpd/httpd/trunk/test/modules/http2/test_203_rfc9113.py Tue Jun 2 15:04:06 2026 (r1934890)
+++ httpd/httpd/trunk/test/modules/http2/test_203_rfc9113.py Tue Jun 2 15:50:29 2026 (r1934891)
@@ -12,6 +12,18 @@ class TestRfc9113:
def _class_scope(self, env):
H2Conf(env).add_vhost_test1().install()
assert env.apache_restart() == 0
+ # test_h2_203_02 sends a response header with an illegal char on
+ # purpose; httpd rightly rejects it with AH02430 and RST_STREAMs the
+ # request. With HTTP/2 that error is emitted *late*, during stream
+ # teardown, and a single case can produce several AH02430 lines spread
+ # over time -- so a per-case ignore_recent() races the stragglers,
+ # which then surface in a later test's check_error_log() (the timing,
+ # and thus which MPM trips, varies with sync vs async h2 handoff).
+ # AH02430 is only ever produced here intentionally, so ignore it for
+ # the whole class; restore the prior set afterwards so it does not leak.
+ env.httpd_error_log.add_ignored_lognos(['AH02430'])
+ yield
+ env.httpd_error_log.remove_ignored_lognos(['AH02430'])
# by default, we accept leading/trailing ws in request fields
def test_h2_203_01_ws_ignore(self, env):
Modified: httpd/httpd/trunk/test/pyhttpd/log.py
==============================================================================
--- httpd/httpd/trunk/test/pyhttpd/log.py Tue Jun 2 15:04:06 2026 (r1934890)
+++ httpd/httpd/trunk/test/pyhttpd/log.py Tue Jun 2 15:50:29 2026 (r1934891)
@@ -76,6 +76,10 @@ class HttpdErrorLog:
for l in lognos:
self._ignored_lognos.add(l)
+ def remove_ignored_lognos(self, lognos: List[str]):
+ for l in lognos:
+ self._ignored_lognos.discard(l)
+
def _is_ignored(self, line: str) -> bool:
if self._lookup_matches(line, self._ignored_matches):
return True
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.