#4006 missing test handler: match_all
Closed: Invalid by kevin. Opened by kevin.

We have in our hub policy:

scm =
      # allow scratch builds from any commits
      bool scratch :: allow
      match_all branches * !! deny Commit must be present on some branch
      all :: allow

This works with 1.33.x, but with 1.34.0, the hub crashes with:

[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] 2024-02-06 18:41:19,784 [WARNING] m=None u=None p=4855 r=?:? koji: Setting resource limit: RLIMIT_AS = [10737418240, -1]
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] 2024-02-06 18:41:20,158 [ERROR] m=None u=None p=4855 r=?:? koji: Traceback (most recent call last):
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/koji/policy.py", line 304, in get_test_handler
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     return self.tests[name](str)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]            ~~~~~~~~~~^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] KeyError: 'match_all'
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] 
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] During handling of the above exception, another exception occurred:
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] 
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] Traceback (most recent call last):
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/kojihub/kojixmlrpc.py", line 747, in server_setup
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     policy = get_policy(opts, plugins)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]              ^^^^^^^^^^^^^^^^^^^^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/kojihub/kojixmlrpc.py", line 648, in get_policy
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     policy[pname] = koji.policy.SimpleRuleSet(text.splitlines(), merged)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/koji/policy.py", line 209, in __init__
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     self.rules = self.parse_rules(rules)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]                  ^^^^^^^^^^^^^^^^^^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/koji/policy.py", line 238, in parse_rules
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     rule = self.parse_line(line)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]            ^^^^^^^^^^^^^^^^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/koji/policy.py", line 296, in parse_line
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     tests = [self.get_test_handler(x) for x in tests.split('&&')]
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]              ^^^^^^^^^^^^^^^^^^^^^^^^
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]   File "/usr/lib/python3.12/site-packages/koji/policy.py", line 306, in get_test_handler
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260]     raise koji.GenericError("missing test handler: %s" % name)
[wsgi:error] [pid 4855:tid 4883] [client 10.3.166.74:51260] koji.GenericError: missing test handler: match_all

Ugh. I am dumb. I thought the scm plugin was merged... but it hasn't been yet. ;)

Sorry for the noise.

Metadata Update from @kevin:
- Custom field Size adjusted to None
- Issue close_status updated to: Invalid
- Issue status updated to: Closed (was: Open)

This issue has been migrated to Fedora Forge:
https://forge.fedoraproject.org/koji/koji/issues/4006

Please continue any further discussion there.

Metadata