mirror of https://github.com/Mikaela/Limnoria.git
Updated to be a bit more robust.
This commit is contained in:
parent
49c3f0c6f7
commit
98f0d46266
|
@ -59,11 +59,11 @@ import textwrap
|
||||||
started = time.time()
|
started = time.time()
|
||||||
|
|
||||||
import supybot
|
import supybot
|
||||||
|
import supybot.utils as utils
|
||||||
import supybot.registry as registry
|
import supybot.registry as registry
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
import supybot.conf as conf
|
import supybot.conf as conf
|
||||||
import supybot.utils as utils
|
|
||||||
import supybot.world as world
|
import supybot.world as world
|
||||||
import supybot.drivers as drivers
|
import supybot.drivers as drivers
|
||||||
import supybot.schedule as schedule
|
import supybot.schedule as schedule
|
||||||
|
@ -279,7 +279,13 @@ if __name__ == '__main__':
|
||||||
irc = irclib.Irc(network=defaultNetwork)
|
irc = irclib.Irc(network=defaultNetwork)
|
||||||
callback = Owner.Class()
|
callback = Owner.Class()
|
||||||
irc.addCallback(callback)
|
irc.addCallback(callback)
|
||||||
|
try:
|
||||||
driver = drivers.newDriver(irc)
|
driver = drivers.newDriver(irc)
|
||||||
|
except Exception, e:
|
||||||
|
log.error(utils.normalizeWhitespace("""I couldn't create a network
|
||||||
|
driver for connecting to IRC. The specific error was this: %s"""),
|
||||||
|
utils.exnToString(e))
|
||||||
|
sys.exit(-1)
|
||||||
|
|
||||||
if options.debug:
|
if options.debug:
|
||||||
for (name, module) in sys.modules.iteritems():
|
for (name, module) in sys.modules.iteritems():
|
||||||
|
|
Loading…
Reference in New Issue