Page 1 of 1

r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 22 Jun 2015, 02:24
by Liposo
Just updated to revision 8977, I got this error multiple times.

Code: Select all

Use of uninitialized value in string eq at src/ChatQueue.pm line 83.
Use of uninitialized value $user in string ne at src/ChatQueue.pm line 89.
Use of uninitialized value $ChatQueue::config{"callSign"} in quotemeta at src/ChatQueue.pm line 106.
Use of uninitialized value $user in hash element at src/ChatQueue.pm line 107.
Pretty sure it's from the update because ChatQueue.pm was updated in this revision. All my configs remained intact.

Re: uninitialized value $ChatQueue::config{"callSign"}

Posted: 22 Jun 2015, 02:46
by vitriol
did you change your config files? it may be caused by a new bug or by a change to your config file

Re: uninitialized value $ChatQueue::config{"callSign"}

Posted: 22 Jun 2015, 07:53
by Liposo
No, I haven't made any change after updating to that revision.

Re: r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 23 Jun 2015, 00:58
by vitriol
maybe somebody made a change that requires specific format of the config files. check for extra spaces or formatting problems

Re: r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 25 Jun 2015, 11:31
by Liposo
Can anyone confirm this? Please.

Re: r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 04 Jul 2015, 04:24
by Liposo
Bug still persists in r8978.

Re: r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 05 Jul 2015, 02:04
by vitriol
download older revisions and check each to see exactly which revision broke it. then "diff" it to the previous revision and find the code that broke your config and fix it and ask a dev to commit your change to svn. you can find help on opk irc channel

Re: r8977 - uninitialized value $ChatQueue::config{"callSign"}

Posted: 09 Jul 2015, 01:33
by Liposo
It's exactly r8977 that the problem was introduced. It was no issue in the earlier revisions.
Also r8977 changelog clearly mentions that ChatQueue.pm was changed.
Code cleanup in aisle /openkore/openkore/trunk/src/ChatQueue.pm !!
This commit is a perfect example showing why we MUST have both
use warnings;
use strict;
in every module to show that we both have bad code in there now, and to
prevent further bad code from being added without being noticed.

- Added "use warnings;"
- sub processChatCommand: In the "move" block, removed an if-elsif that
did *nothing* and has been in the codebase since the module was
created, nearly ELEVEN years ago!