本文整理汇总了Python中log.LOG.i方法的典型用法代码示例。如果您正苦于以下问题:Python LOG.i方法的具体用法?Python LOG.i怎么用?Python LOG.i使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类log.LOG
的用法示例。
在下文中一共展示了LOG.i方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: analyseResponse
# 需要导入模块: from log import LOG [as 别名]
# 或者: from log.LOG import i [as 别名]
return analyseResponse(msg, '</font><br>')
except:
if 1 == kwid:
return analyseResponse(msg, '可看笑话分类<br>')
if 3 == kwid:
return analyseResponse(msg, '<br></font>')
if __name__ == '__main__':
username = raw_input('UserName: ')
password = raw_input('PassWord: ')
# 登录白云黄鹤
byhh = BYHH(username, password)
cookie = byhh.login()
log.i(cookie)
# 加载城市名称和城市id
cityidDict = pickle.load(file(cwd + 'cityid', 'r'))
# 加载SpecialWords列表
specialWordsList = open(cwd + 'SpecialWords', 'r').readline().split(';')
specialWordsDict = {}
for sw in specialWordsList:
specialWordsDict[sw.split(':')[0]] = sw.split(':')[1]
# 加载sensitiveWords列表
sensitiveWordsList = open(cwd + 'SensitiveWords', 'r').readline().split(';')
while True:
# 获取新鲜事列表页面,返回首个新鲜事Url
news = NEWS()
示例2: _bbssnd
# 需要导入模块: from log import LOG [as 别名]
# 或者: from log.LOG import i [as 别名]
self.title = title
self.text = text
self.signature = signature
self.start = start
def _bbssnd(self, url, cookie):
req = urllib2.Request(url, urllib.urlencode({'title': self.title, 'signature': self.signature, 'start': self.start, 'text': self.text}))
req.add_header('Cookie', cookie)
print urllib2.urlopen(req).read()
def bbssnd(self, url, cookie):
try:
return self._bbssnd(url, cookie)
except:
return self.bbssnd(url, cookie)
def hanzi(hz):
return hz.decode('utf8').encode('GB18030')
if __name__ == '__main__':
username = raw_input('UserName: ')
password = raw_input('PassWord: ')
# 登录白云黄鹤
byhh = BYHH(username, password)
cookie = byhh.login()
log.i(cookie)