Intermittent undefined hook removal assertion during cleanup
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 25/100
Direzione di ricerca
Start by reading src/Utils/ObjectList.pm (remove/clear) to see where the assertion is raised, then src/Plugins.pm (delHook) and src/InventoryList.pm (DESTROY) for the call chain. Try to reproduce with make test and, since it is intermittent, consider running the suite repeatedly or with a random test order. Note that pull request #4399 is already open against this issue, so coordinate there before writing code; done means the undefined handle is traced and the test command exits nonzero on a cleanup assertion.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Openkore version git
OpenKore git development tree; exact commit at the time of the warning was not recorded
XKore Mode
Empty
RO Server Name
N/A — unit tests; no Ragnarok server was involved
Link to RO server
N/A — unit tests; no server link applies
Result
During one execution of OpenKore's unit test suite, the TAP plan completed with all 1,923 tests passing, then Perl emitted:
(in cleanup) Assertion (Can't remove undefined item) failed!
The test runner returned exit code 0 despite the cleanup assertion. The warning appeared once and did not recur in four subsequent runs on either the development branch or its unchanged base. There is no confirmed reproduction sequence or root cause.
This was noticed while validating unrelated XSTools compatibility work. The cleanup code described below was unchanged by that work. No gameplay impact has been confirmed.
Potentially relevant current code:
src/InventoryList.pm,InventoryList::DESTROY, invokesPlugins::delHookfor stored hook handles before clearing the list.src/Plugins.pm,Plugins::delHook, gets an entry by saved hook index and passes it toremovewithout a defined check.src/Utils/ObjectList.pm,ObjectList::remove, asserts that the item is defined using the observed assertion text.
This code relationship is worth investigating, but it does not establish that this path caused the observed warning. Possible explanations include stale hook handles, duplicate removal, an invalidated index, or object destruction order.
Related history:
- #225 — Quitting has errors included an undefined entry passed to
ObjectList::removefromPlugins::delHookduring shutdown, along with an inventory cleanup assertion. It closed in 2017 after a comment that inventory lists had been updated. A shared root cause is unconfirmed. - #408 — Assertion (invIndex must be defined) failed, after running tests reported an intermittent post-test assertion in
InventoryList::DESTROY/ObjectList::clear. It was closed in November 2026 with a comment that it had not recurred for years. That assertion is distinct. - #4107 — Invalid hook handle passed to Plugins.delHook reported a shutdown-time invalid hook handle and was closed in 2025; the behavior differs from this observation.
This report does not attribute the warning to macOS, Apple Silicon, a particular Perl version, or XSTools.
Relevant Log Output
(in cleanup) Assertion (Can't remove undefined item) failed!
Expected Result
Ideally, test cleanup should complete without this assertion. If a cleanup assertion does occur, the test command should report failure with a nonzero exit status so automation does not silently pass.
How to Reproduce
The issue is intermittent and no deterministic reproduction is known. In one make test execution, all 1,923 TAP tests passed, then the cleanup assertion appeared and the command returned exit code 0. It did not recur in four subsequent runs on either the development branch or its unchanged base.
- Lingua principale
- Perl
- Stelle
- 1.5k
- Fork
- 1.2k
- Merge medio
- 11h
- PR unite (30g)
- 110
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di OpenKore/openkore
-
fix(char-create): show the real reason a character is refusedForse già presa @baphomello l’ha presa 1 giorno fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
-
fix(manner): show the real result of manner and mute packetsForse già presa @baphomello l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 45/100
I maintainer di solito rispondono entro 1 giorno
-
fix(utils): skip repeated delimiters in parseArgsForse già presa @baphomello l’ha presa 1 giorno fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 42/100
I maintainer di solito rispondono entro 1 giorno
-
fix(talknpc): bind server-started dialogs to the packet NPCForse già presa @baphomello l’ha presa 2 giorni fa. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 1/100
I maintainer di solito rispondono entro 1 giorno
-
Will WX's interface get a dark mode?Forse già presa @baphomello l’ha presa 7 giorni fa. Apertafeature request
Difficoltà 5/5 Più di una settimana Idoneità per principianti 15/100
OpenKore/openkore#4316 · 4 commenti ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di OpenKore/openkore
Issue simili
-
area:runtime bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
fglock/PerlOnJava#2164 ·
I maintainer di solito rispondono entro 1 giorno
-
Dev-output directory preparation accepts file-valued lib/include paths and fails on dangling linksApertateam-cli
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 93/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
inverse-inc/packetfence#9728 ·
I maintainer di solito rispondono entro 1 giorno