0

i can't import zxlolbot.py have problem...

No handlers could be found for logger "zxlolbot"

Biffen
  • 6,249
  • 6
  • 28
  • 36

2 Answers2

0

This sounds like you didn't set up the logging module properly.

Aaron Digulla
  • 321,842
  • 108
  • 597
  • 820
0

It means zxlolbot uses logging module without configuring it properly. You should see:

logger = logging.getLogger(__name__)

in zxlolbot.py. Add this line after it:

logger.addHandler(logging.NullHandler())

To save logging messages to a file, you could add in bot.py:

if __name__=="__main__":
    import logging
    logging.basicConfig(filename='bot.log', level=logging.INFO)
jfs
  • 399,953
  • 195
  • 994
  • 1,670