collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18363
  • stats Total Topics: 2500
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: Read error: EOF on whois/Buddy-Add event  (Read 11175 times)

0 Members and 1 Guest are viewing this topic.

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Read error: EOF on whois/Buddy-Add event
« on: October 14, 2009, 12:59:56 pm »
Hi all,

First of all, thanks for this cool development. Our guild enjoys using the bot a lot.
I do have a small problem; I get Read Error: EOF fairly frequently. From what I can tell from console, this happens most in relation to someone doing !whois, particularly on a character that doesn't exist.
It looks like if a !whois is done, it triggers a Buddy-Add event, and if this person does not exist the event fails and the bot disconnects with an EOF error.
Here's some output:

Code: [Select]
Thespeaker [TELL]       [INC]   Sunay: !whois Sephpom                                                                                                                                                                                                                                                                     
Thespeaker [TELL]       [OUT]   -> Sunay: Sephpom is a level 20 Priest of Mitra :: Offline :: Alt of Sephiriot :: [link]Details[/link]                                                                                                                                                                                     
Thespeaker [TELL]       [INC]   Sunay: !whois ach                                                                                                                                                                                                                                                                         
Thespeaker [BUDDY]      [BUDDY-ADD]     Ach                                                                                                                                                                                                                                                                               
Read error: EOF                                                                                                                                                                                                                                                                                                           
Thespeaker [CONN]       [ERROR] Bot has disconnected. Reconnecting in 60 seconds.

The bot then reconnects and works ok, until this scenario occurs again.
I have also seen it happen on other Buddy-Add events, not sure what triggered them.
Any ideas what needs changing to fix it?

Thanks in advance!




Offline Getrix

  • Contributor
  • *******
  • Posts: 509
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #1 on: October 14, 2009, 01:03:26 pm »
Hi, are you running latest stable 0.6.5?
Success is not final, failure is not fatal: it is the courage to continue that counts.
- Sorry, i dont have time to reply question on PM. Make a topic.

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #2 on: October 14, 2009, 01:08:02 pm »
Sorry. I forgot to include that ><
Yes this is the latest stable version.

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #3 on: October 14, 2009, 05:43:22 pm »
Would it have anything to do with the code mentioned in this thread?

http://bebot.link/aoc-modules/autogratz-doesn%27t-gratz-%28/

My Main.php contains the code

Code: [Select]
case 20:
         // Silently ignore for now (AOCP_CLIENT_NAME)
         break;
      case AOCP_MSG_PRIVATE:
         // Event is a tell

and not

Code: [Select]
  case 20:
         // Silently ignore for now (AOCP_CLIENT_NAME)
         if ($bot -> aoc -> buddy_exists($args[0]))
         {
            $bot -> aoc -> buddy_remove($args[0]);
            $bot -> aoc -> buddy_add($args[0]);
         }
         break;
      case AOCP_MSG_PRIVATE:
         // Event is a tell

Offline Khalem

  • BeBot Founder
  • Administrator
  • ********
  • Posts: 1169
  • Karma: +0/-0
    • http://www.ancarim.com
Re: Read error: EOF on whois/Buddy-Add event
« Reply #4 on: October 14, 2009, 07:32:58 pm »
This looks like a nasty bug.

I'll see if i can find some time to do some testing on this.
BeBot Founder and Fixer Kingpin

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #5 on: October 15, 2009, 12:49:55 am »
Thank you! If I can assist in testing in any way, please let me know.

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #6 on: October 15, 2009, 08:29:30 pm »
One more update; apparently there is a buddy-add event in queue for whenever one particular user logs on. The user will logon and thus join the guild channel, the bot signals this, and tries to run the same buddy-add event every time, resulting in a crash. The bot then restarts, logs on again after a while, and since the user is already in the channel the event doesn't reoccur. When user logs off and on again however, the same scenario repeats.
See log here:
Code: [Select]
Thespeaker [BUDDY]      [LOG]   Nimu changed status [1] (MEMBER)                                                                                                                                                                                                                                                           
Thespeaker [BUDDY]      [BUDDY-ADD]     Torden                                                                                                                                                                                                                                                                             
Thespeaker [BUDDY]      [LOG]   Nimu changed status [6] (MEMBER)                                                                                                                                                                                                                                                           
Read error: EOF                                                                                                                                                                                                                                                                                                           
Thespeaker [CONN]       [ERROR] Bot has disconnected. Reconnecting in 60 seconds.                                                                                                                                                                                                                                         
The bot is restarting.                                                                                                                         



Is there any way for me to remove this recurring buddy-add event for this particular user?

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #7 on: October 15, 2009, 08:45:33 pm »
I have just narrowed it down a bit more. As it turns out, the user crashing the !whois was not a member of the guild. I mean, the person doing the whois is, but the person on whom the whois was done was not.
I have made this target person a guild member, triggering a different kind of adduser event, and the problem is gone.
It seems this issue only occurs when someone does a !whois on a character not known to the bot.
Hope that helps the code checking :)

Offline Apollyon

  • BeBot User
  • **
  • Posts: 21
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #8 on: November 03, 2009, 03:17:47 am »
Was anything ever resolved with this?  I think I am getting a similar issue with the 6.6 version, but I have not had a chance to look into it much yet.  I will post more when I can.

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #9 on: November 03, 2009, 12:06:15 pm »
I still get the same problem when the BUDDY-ADD queue that is displayed on bot startup is too big. It usually lists some people that have left the guild, and then ends in EOF.


Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #10 on: November 06, 2009, 03:51:40 pm »
The same problem is again happening, this time for a character that is in the "BUDDY-ADD" queue that has already been deleted (from the game). The character in question is an alt of an existing member.
Everytime this member logs on, on his main or any of his alts, the bot dies as it initiates a buddy-add for the deleted character at this time - causing the EOF error.
Right now I have no way of clearing this queue as far as I know - so whenever he shows up, the bot dies.
Is there any way to fix this?


Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #11 on: November 08, 2009, 01:19:26 am »
Well, it's come back with a vengeance - i see lots of buddy-add events when either people log on who have done a !whois on this person, or when people join who have an alt who is on this list...and even people who left the guild and have been deleted as a member.
The bot keeps trying to add them in the buddy-add queue, which causes an EOF, and crashes.
That makes the bot reconnect, which of course boots me from the game :)

Any suggestions would be appreciated.

Offline Khalem

  • BeBot Founder
  • Administrator
  • ********
  • Posts: 1169
  • Karma: +0/-0
    • http://www.ancarim.com
Re: Read error: EOF on whois/Buddy-Add event
« Reply #12 on: November 13, 2009, 01:44:01 pm »
Sorry for the delay on this. Studies have been keeping me far to busy as of late.

I've been thinking about this one for a bit and I'm a bit puzzeled at what is actually going on.

Try adding the following debug code so we can get a better idea of what is happeneing:
main/15_AOChatWrapper.php
Find
Code: [Select]
$this -> bot -> aoc -> buddy_add($uid);
$this -> bot -> log("BUDDY", "BUDDY-ADD", $this -> get_uname($uid));

Replace with:
Code: [Select]
$this -> bot -> log("BUDDY", "BUDDY-ADD", $this -> get_uname($uid) . '(' . $uid . ')');
$this -> bot -> aoc -> buddy_add($uid);

(Notice also the changed order)

Next, Sources\AOChat.php, find the function add_buddy and add the following line before the last return call
Code: [Select]
echo "Debug: buddy_add called with final UID $uid passed to server.\n";

Hopefully this will give a better idea of what is going on.
BeBot Founder and Fixer Kingpin

Offline Baldrick

  • BeBot User
  • **
  • Posts: 25
  • Karma: +0/-0
Re: Read error: EOF on whois/Buddy-Add event
« Reply #13 on: November 16, 2009, 03:13:12 pm »
No worries, I appreciate the time you've put into this project.

In the meantime I had decided to completely reinstall the bot, new SQL database, new code download, new bare PHP.ini.
I then added my favorite modules back in and let it run as usual.

Although this wasn't a bad exercise to begin with because everything is nice, clean and fast, it didn't resolve the issue. The "stuck queue" was obviously cleared, but I did see it occurring again with a queued up buddy-add event where it actually tried to add an entity displaying the ID rather than the nickname, and I got the familiar EOF.
I then decided to switch off the buddy-queue altogether and have not had an issue since.

If anyone else has this problem and you want to troubleshoot the issue, I'm willing to switch the buddy-queue back on and add in the code, but it might be a while before the issue occurs again as the "queue" is now empty and the error is not always triggered.

If I'm the only one who had this then I'd say switching off buddy-queueing is a good enough solution for me.

Let's see who replies :)

Cheers,

B

Offline clashbot

  • BeBot Expert
  • ****
  • Posts: 295
  • Karma: +0/-0
    • Ascension's Home
Re: Read error: EOF on whois/Buddy-Add event
« Reply #14 on: November 17, 2009, 02:33:52 am »
one thing you can try, is to log onto the bot toon, and manually delete the offending toon from the friends list. See if that resolves, or temporarily patches your error...Otherwise it might be a problem with the org xml on funcom's server as I ran into something similar a long time ago concerning an orgmate who's name was changed by a GM. Caused all sorts of hell for the bot.

 

* Recent Posts
[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm]


0.8.x updates for AoC by bitnykk
[January 30, 2024, 11:16:08 pm]


0.8.x updates for AO by bitnykk
[January 30, 2024, 11:15:37 pm]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am]


Bebot and Rasberry by bitnykk
[November 29, 2023, 11:04:14 pm]

* Who's Online
  • Dot Guests: 514
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal