egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

External script taking too long to execute?

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
elal
Voice


Joined: 19 Aug 2009
Posts: 1

PostPosted: Wed Aug 19, 2009 8:21 pm    Post subject: External script taking too long to execute? Reply with quote

I am writing a TCL script for the eggdrop bot. The primary function of this TCL script is to call an external BASH script. The BASH script takes a variable amount of time to execute, because it must first download software, and sometimes that software is rather large.

During those times when the BASH script is downloading a large file, there appears to be some sort of time-out issue, because the TCL script never produces any result to the channel. The external BASH script succeeds, but its output never reaches the TCL script which called it.

During those times when the bash script is only downloading *small* files, the output from the bash script reaches the TCL caller, and everything is fine.

Is anyone familiar with external script timeouts in eggdrop/TCL scripts?
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Thu Aug 20, 2009 7:01 pm    Post subject: Reply with quote

Your best option would be to use the "open" command with pipes. This allows you to interact with the stdin/stdout pipes of your script as if it was any ordinary file, while at the same time the script will not block tcl (and thus not eggdrop either).
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber