Mozbot/FAQ: Difference between revisions

138 bytes removed ,  12 August 2013
no edit summary
(Created page with "==What is mozbot?== Mozbot is an IRC [http://www.tuxedo.org/~esr/jargon/html/entry/bot.html bot]. Originally designed specifically for the irc.mozilla.org community, it has [http...")
 
No edit summary
Line 1: Line 1:
==What is mozbot?==
==What is mozbot?==
Mozbot is an IRC [http://www.tuxedo.org/~esr/jargon/html/entry/bot.html bot]. Originally designed specifically for the irc.mozilla.org community, it has [http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fwebtools%2Fmozbot&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=all&mindate=&maxdate=&cvsroot=%2Fcvsroot grown] into a multipurpose bot with many features.
Mozbot is an IRC [http://www.tuxedo.org/~esr/jargon/html/entry/bot.html bot].
===What does it do?===
Originally designed specifically for the irc.mozilla.org community,
Quite a bit! Mozbot provides helpful services to the developer communities using other Mozilla webtools, such as displaying information on bug reports from [http://www.bugzilla.org Bugzilla], displaying changes in the Tinderbox status, and reporting the sheriff of the tree. Mozbot also provides several important services to keep IRC working well, such as giving ops to trusted users and keeping channels open and the right people in control. There are also Infobot and Quizbot modules. For more information, see the [[Mozbot/Documentation/Modules|modules documentation]].
it has [http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fwebtools%2Fmozbot&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=all&mindate=&maxdate=&cvsroot=%2Fcvsroot grown]
===Modules?===
into a multipurpose bot with many features.
Mozbot is important because it allows developers to write bot modules in perl using the mozbot APIs. If you are interested in writing modules, take a look at our [[Mozbot/Hacking|Introduction to Hacking Mozbot]]. Modules can be installed and updated on the fly, without shutting down the bot.
==What does it do?==
 
Quite a bit! Mozbot provides helpful services to the developer
So, I want mozbot to auto-op people in my channel, how can I?
communities using other Mozilla webtools, such as displaying
 
information on bug reports from [http://www.bugzilla.org Bugzilla], displaying changes in the [../tinderbox/ Tinderbox] status, and reporting the
See the [[Mozbot/Documentation/Oping|God module documentation]].
sheriff of the tree. Mozbot also provides several important
===Where can I get the source/get involved?===
services to keep IRC working well, such as giving ops to trusted
Mozbot is written in Perl and is free software under the terms of the MPL. Mozbot is <a href="download.html#cvs">available through CVS</a>. If you want to write modules or fix bugs, take a look at our <a href="hacking.html">Introduction to Hacking Mozbot</a> and come chat to us in <a href="irc://irc.mozilla.org/%23mozwebtools">#mozwebtools</a>.
users and keeping channels open and the right people in control.
 
There are also Infobot and Quizbot modules. For more information,
Mozbot doesn't connect to the IRC server on my dual-homed box.
see the [docs/#modules modules] documentation.
 
==Modules?==
Open up your config file and append localAddr=192.168.0.1 where the IP address is that of the interface to use. You must be using <a href="http://search.cpan.org/search?dist=Net-IRC">Net::IRC</a> 0.71 or above for this to work.
Mozbot is important because it allows developers to write bot
 
modules in perl using the mozbot APIs. If you are interested in
See <a href="http://bugzilla.mozilla.org/show_bug.cgi?id=93186" title="mozbot may not connect on dual-homed boxes">bug 93186</a> for more details.
writing modules, take a look at our [hacking.html Introduction to
 
Hacking Mozbot]. Modules can be installed and updated on the
Mozbot doesn't connect to the IRC server on my unnamed box.
fly, without shutting down the bot.
 
==So, I want mozbot to auto-op people in my channel, how can I?==
See the [docs/oping.html God module]
documentation.
==Where can I get the source/get involved?==
Mozbot is written in Perl and is free software under the terms
of the MPL. Mozbot is [download.html#cvs available through
CVS]. If you want to write modules or fix bugs, take a look at
our [hacking.html Introduction to Hacking Mozbot] and
come chat to us in [irc://irc.mozilla.org/%23mozwebtools #mozwebtools].
<dt id="localAddr Mozbot doesn't connect to the IRC server on my dual-homed box.==
Open up your config file and append
<code>localAddr=192.168.0.1</code> where the IP address is that of
the interface to use. You must be using [http://search.cpan.org/search?dist=Net-IRC Net::IRC] 0.71
or above for this to work.
See [http://bugzilla.mozilla.org/show_bug.cgi?id=93186 bug 93186]
for more details.
==Mozbot doesn't connect to the IRC server on my unnamed box.==
Give your host a hostname.
Give your host a hostname.
 
==So far we're not getting many responses from the new bot...
So far we're not getting many responses from the new bot...what's something simple to try?
what's something simple to try?==
 
First thing to do is to load some modules. To do this you'll
First thing to do is to load some modules. To do this you'll need to authenticate as an administrator. You can read all about that in the <a href="http://lxr.mozilla.org/mozilla/source/webtools/mozbot/INSTALL#165">installation instructions</a>. Once you've done that, say <kbd>/msg mozbot load Greeting</kbd>, where <code>Greeting</code> is the name of a module to load. You can see the list of standard modules on the <a href="docs/">documentation page</a>.
need to authenticate as an administrator. You can read all about
 
that in the [http://lxr.mozilla.org/mozilla/source/webtools/mozbot/INSTALL#165 installation
Mozbot keeps getting kicked for flooding.
instructions]. Once you've done that, say <kbd>/msg mozbot load
 
Greeting</kbd>, where <code>Greeting</code> is the name of a module
Increase the <code>throttleTime</code> variable in the Admin module. For example, this is how Hixie increased the throttle time of his bot called oopsbot:
to load. You can see the list of standard modules on the [docs/ documentation page].
==Mozbot keeps getting kicked for flooding.==
Increase the <code>throttleTime</code> variable in the Admin
module. For example, this is how Hixie increased the throttle time
of his bot called oopsbot:
<pre>
<pre>
  &lt;Hixie&gt; <kbd>oopsbot: vars Admin throttleTime</kbd>
&lt;Hixie&gt; <kbd>oopsbot: vars Admin throttleTime</kbd>
&lt;oopsbot&gt; Variable 'throttleTime' in module 'Admin' is set to: '1.3'
&lt;oopsbot&gt; Variable 'throttleTime' in module 'Admin' is set to: '1.3'
  &lt;Hixie&gt; <kbd>oopsbot: vars Admin throttleTime '1.6'</kbd>
&lt;Hixie&gt; <kbd>oopsbot: vars Admin throttleTime '1.6'</kbd>
&lt;oopsbot&gt; Variable 'throttleTime' in module 'Admin' has changed.
&lt;oopsbot&gt; Variable 'throttleTime' in module 'Admin' has changed.
</pre>
</pre>
 
There is no correct value for this variable; different servers use
There is no correct value for this variable; different servers use different algorithms to determine who is speaking too much. Tweak it until you are happy with the compromise between your bot's response time and its likelyhood of getting kicked during heavy use. (Note: You have to be authenticated as bot admin for this to work. See the <a href="http://lxr.mozilla.org/mozilla/source/webtools/mozbot/INSTALL#165">installation instructions</a> for details.)
different algorithms to determine who is speaking too much. Tweak
 
it until you are happy with the compromise between your bot's
===What platforms does mozbot run on?===
response time and its likelyhood of getting kicked during heavy
 
use. (Note: You have to be authenticated as bot admin for this to
It's been seen running on most flavours of Linux, BSD and MacOSX. On Windows, there are serious issues with any module that tries to fork(). That includes basically any module that uses FTP or tries to go to a website. Patches welcome! :-)
work. See the [http://lxr.mozilla.org/mozilla/source/webtools/mozbot/INSTALL#165 installation
 
instructions] for details.)
I just found a bug in mozbot, where do I report it?
==What platforms does mozbot run on?==
[http://bugzilla.mozilla.org/enter_bug.cgi?reporter=ian%40hixie.ch&amp;product=Webtools&amp;version=other&amp;component=Mozbot&amp;rep_platform=PC&amp;op_sys=Linux&amp;priority=--&amp;bug_severity=normal&amp;assigned_to=&amp;cc=&amp;bug_file_loc=&amp;short_desc=&amp;comment=STEPS+TO+REPRODUCE%0D%0A+++1.+%0D%0A+++2.+%0D%0A+++3.%0D%0A%0D%0ASEEN+WITH%0D%0A+++Server%3A+%0D%0A+++Bot%3A+&amp;maketemplate=Remember+values+as+bookmarkable+template&amp;form_name=enter_bug In Bugzilla]. Please include as many details as possible.
It's been seen running on most flavours of Linux, BSD and
MacOSX. On Windows, there are serious issues with any module that
tries to fork(). That includes basically any module that uses FTP
or tries to go to a website. Patches welcome! :-)
==I just found a bug in mozbot, where do I report it?==
[http://bugzilla.mozilla.org/enter_bug.cgi?reporter=ian%40hixie.ch&amp;product=Webtools&amp;version=other&amp;component=Mozbot&amp;rep_platform=PC&amp;op_sys=Linux&amp;priority=--&amp;bug_severity=normal&amp;assigned_to=&amp;cc=&amp;bug_file_loc=&amp;short_desc=&amp;comment=STEPS+TO+REPRODUCE%0D%0A+++1.+%0D%0A+++2.+%0D%0A+++3.%0D%0A%0D%0ASEEN+WITH%0D%0A+++Server%3A+%0D%0A+++Bot%3A+&amp;maketemplate=Remember+values+as+bookmarkable+template&amp;form_name=enter_bug In
Bugzilla.] Please include as many details as possible.
94

edits