forked from liuwons/wxBot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Format code and solve the dead cycle problem.
- Loading branch information
Showing
3 changed files
with
751 additions
and
703 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,28 @@ | ||
#!/usr/bin/env python | ||
# coding: utf-8 | ||
|
||
from wxbot import * | ||
|
||
|
||
class MyWXBot(WXBot): | ||
def handle_msg_all(self, msg): | ||
if msg['msg_type_id'] == 4 and msg['content']['type'] == 0: | ||
self.send_msg_by_uid('hi', msg['user']['id']) | ||
''' | ||
def schedule(self): | ||
self.send_msg('tb', 'schedule') | ||
time.sleep(1) | ||
''' | ||
|
||
|
||
def main(): | ||
bot = MyWXBot() | ||
bot.DEBUG = True | ||
bot.conf['qr'] = 'png' | ||
bot.run() | ||
|
||
|
||
if __name__ == '__main__': | ||
main() | ||
#!/usr/bin/env python | ||
# coding: utf-8 | ||
|
||
from wxbot import * | ||
|
||
|
||
class MyWXBot(WXBot): | ||
def handle_msg_all(self, msg): | ||
if msg['msg_type_id'] == 4 and msg['content']['type'] == 0: | ||
self.send_msg_by_uid('hi', msg['user']['id']) | ||
|
||
|
||
''' | ||
def schedule(self): | ||
self.send_msg('tb', 'schedule') | ||
time.sleep(1) | ||
''' | ||
|
||
|
||
def main(): | ||
bot = MyWXBot() | ||
bot.DEBUG = True | ||
bot.conf['qr'] = 'png' | ||
bot.run() | ||
|
||
|
||
if __name__ == '__main__': | ||
main() |
Oops, something went wrong.