Project

General

Profile

Actions

Bug #73676

closed
KS

Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in lua

Bug #73676: Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in lua

Added by Kyr Shatskyy about 1 year ago. Updated about 1 month ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Due date:
% Done:

0%

Source:
Backport:
tentacle, squid
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
fs
Component(FS):
qa-suite, tools
Labels (FS):
qa
Pull request ID:
Tags (freeform):
Fixed In:
v20.3.0-5238-gaf57cb7337
Released In:
v21.2.0~1293
Upkeep Timestamp:
2026-10-24T02:02:32+00:00

Description

Premerge stage is dies with KeyError: 'kernel' when using option -k none which is valid and used for kvm test nodes .

2025-10-30 09:20:09,044.044 DEBUG:teuthology.suite.merge:premerge script running:
local set = yaml.teuthology.variables.fail_fs
local cmd = "ceph config set mgr mgr/orchestrator/fail_fs "..tostring(set)
local cmds = yaml_fragment['upgrade-tasks'].sequential[0]['cephadm.shell']['host.a']
if set then
  py_attrgetter(cmds).append "ceph config set mgr mgr/orchestrator/fail_fs true" 
else
  py_attrgetter(cmds).append "ceph config set mgr mgr/orchestrator/fail_fs false || true" 
end

2025-10-30 09:20:09,047.047 DEBUG:teuthology.suite.merge:postmerge script running:
local branch = yaml.kernel.branch
if branch and not yaml.kernel.branch:find "-all$" then
  log.debug("removing default kernel specification: %s", yaml.kernel)
  py_attrgetter(yaml.kernel).pop('branch', nil)
  py_attrgetter(yaml.kernel).pop('deb', nil)
  py_attrgetter(yaml.kernel).pop('flavor', nil)
  py_attrgetter(yaml.kernel).pop('kdb', nil)
  py_attrgetter(yaml.kernel).pop('koji', nil)
  py_attrgetter(yaml.kernel).pop('koji_task', nil)
  py_attrgetter(yaml.kernel).pop('rpm', nil)
  py_attrgetter(yaml.kernel).pop('sha1', nil)
  py_attrgetter(yaml.kernel).pop('tag', nil)
end

Traceback (most recent call last):
  File "/home/teuthology/./teuthology/virtualenv/bin/teuthology-suite", line 7, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/teuthology/teuthology/scripts/suite.py", line 237, in main
    return teuthology.suite.main(args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/teuthology/teuthology/teuthology/suite/__init__.py", line 146, in main
    run.prepare_and_schedule()
  File "/home/teuthology/teuthology/teuthology/suite/run.py", line 486, in prepare_and_schedule
    num_jobs = self.schedule_suite()
               ^^^^^^^^^^^^^^^^^^^^^
  File "/home/teuthology/teuthology/teuthology/suite/run.py", line 646, in schedule_suite
    configs = list(config_merge(configs,
              ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/teuthology/teuthology/teuthology/suite/merge.py", line 174, in config_merge
    if not script():
           ^^^^^^^^
  File "lupa/lua54.pyx", line 946, in lupa.lua54._LuaObject.__call__
  File "lupa/lua54.pyx", line 1918, in lupa.lua54.call_lua
  File "lupa/lua54.pyx", line 1944, in lupa.lua54.execute_lua_call
  File "lupa/lua54.pyx", line 413, in lupa.lua54.LuaRuntime.reraise_on_exception
  File "lupa/lua54.pyx", line 2252, in lupa.lua54.py_object_getindex_with_gil
  File "lupa/lua54.pyx", line 2214, in lupa.lua54.getitem_for_lua
KeyError: 'kernel'


Related issues 2 (0 open — 2 closed)

Copied to CephFS - Backport #74852: tentacle: Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in luaResolvedKyr Shatskyy

Actions
Copied to CephFS - Backport #74853: squid: Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in luaResolvedKyr Shatskyy

Actions

KS Updated by Kyr Shatskyy about 1 year ago Actions #1

@Patrick Donnelly do you have an idea how to fix this?

KS Updated by Kyr Shatskyy about 1 year ago Actions #2

May this probably because here https://github.com/ceph/ceph/blob/main/qa/cephfs/begin/3-kernel.yaml Lua does not take into account that kernel can be 'none'?

KS Updated by Kyr Shatskyy about 1 year ago Actions #4

Also, maybe we also fix teuthology in order to handle bad lua code, just print out the exception and continue with suite?

@Zack Cerza @Patrick Donnelly
Your thought about this fix https://github.com/ceph/teuthology/pull/2100

KS Updated by Kyr Shatskyy about 1 year ago Actions #5

  • Backport set to tentacle, squid

KS Updated by Kyr Shatskyy 10 months ago Actions #6

  • Project changed from teuthology to CephFS
  • Category deleted (QA Suite)
  • Pull request ID set to 66092
  • ceph-qa-suite fs added
  • Component(FS) qa-suite, tools added
  • Labels (FS) qa added

Changing domain to ceph because the PR is applied to fs related suite and will require a back port.

UB Updated by Upkeep Bot 10 months ago Actions #7

  • Status changed from New to Pending Backport
  • Merge Commit set to af57cb7337439544336f41e4d4bd43bc17d67ebc
  • Fixed In set to v20.3.0-5238-gaf57cb7337
  • Upkeep Timestamp set to 2026-02-10T13:19:00+00:00

UB Updated by Upkeep Bot 10 months ago Actions #8

  • Copied to Backport #74852: tentacle: Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in lua added

UB Updated by Upkeep Bot 10 months ago Actions #9

  • Copied to Backport #74853: squid: Cannot schedule job when for some suites with -k option because of some KeyError: 'kernel' in lua added

UB Updated by Upkeep Bot 10 months ago Actions #10

  • Tags (freeform) set to backport_processed

UB Updated by Upkeep Bot 5 months ago Actions #11

  • Status changed from Pending Backport to Resolved
  • Upkeep Timestamp changed from 2026-02-10T13:19:00+00:00 to 2026-07-10T13:26:39+00:00

UB Updated by Upkeep Bot 3 months ago Actions #12

  • Tags (freeform) deleted (backport_processed)
  • Upkeep Timestamp changed from 2026-07-10T13:26:39+00:00 to 2026-08-28T01:41:42+00:00

UB Updated by Upkeep Bot about 1 month ago Actions #13

  • Released In set to v21.2.0~1293
  • Upkeep Timestamp changed from 2026-08-28T01:41:42+00:00 to 2026-10-24T02:02:32+00:00
Actions

Also available in: PDF Atom