- 博客(3)
- 问答 (1)
- 收藏
- 关注
原创 多线程爬取糗事百科
1.所用到的模块 request ,queue,time,etree 2.对于多线程知识有一定了解,类的继承,异常处理等 3.构思自己大致的思路。 import threading import queue import requests import time from lxml import etree class thread1(threading.Thread): def __init_...
2019-06-20 14:12:34 140
原创 用smtplib模块发送文本遇到的问题
import smtplib from email.mime.text import MIMEText sender = ‘ycl_***@126.com’ pwd = ‘********’#授权码密码 receive = ‘**********@qq.com’ msg = MIMEText(‘这是一个测试!成功啦’) subject = ‘ycl_0204’ msg[‘From’] = send...
2019-05-28 15:04:19 385
原创 用正则表达式爬取网页电话号码的遇到的问题
import requests import re resp_pat1list=[] resp_pat1list2=[] #请求头 header = {‘User-Agent’:‘Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.108 Safari/53...
2019-05-28 14:54:11 905
空空如也
python网页爬取信息,多个正则表达式爬取,结果出现有一个空值
2019-05-28
TA创建的收藏夹 TA关注的收藏夹
TA关注的人