随笔 - 31  文章 - 0  评论 - 0  阅读 - 2430

随笔分类 -  02-爬虫常用篇

<4> node.js----express服务
摘要:/* express的服务器 */ // 1. 导入express const express = require('express'); const bodyParser = require('body-parser'); // 2. js文件导入 const aesEncrypt = requi 阅读全文
posted @ 2022-11-05 22:49 不是霉蛋 阅读(18) 评论(0) 推荐(0) 编辑
<3> os.popen()获取js结果
摘要:# 访问js文件,获取结果 def decrypto(self, data: str): # 加密字符串 import os with os.popen("node js文件 {}".format(data)) as p: return p.read().strip() # js文件下(弊端:会造成 阅读全文
posted @ 2022-11-04 15:12 不是霉蛋 阅读(47) 评论(0) 推荐(0) 编辑
<2> 线程池---ThreadPoolExecutor
摘要:1 import time 2 from concurrent.futures import ThreadPoolExecutor, as_completed, ProcessPoolExecutor 3 4 5 class Spider: 6 7 executor = ThreadPoolExec 阅读全文
posted @ 2022-11-03 15:28 不是霉蛋 阅读(37) 评论(0) 推荐(0) 编辑
<1> flask服务
摘要:import flask app = flask.Flask(__name_, static_folder='static', template_folder='templates') @app.route("/") def index(): return flask.render_temp1ate 阅读全文
posted @ 2022-11-02 22:53 不是霉蛋 阅读(13) 评论(0) 推荐(0) 编辑

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

点击右上角即可分享
微信分享提示