A spider for https://dimtown.com
Project description
dimtown-spider
⭐基于httpx
的为次元小镇的异步爬虫⭐
⭐ 介绍
- 本项目采用
Apache License 2.0
开源协议。在使用这个项目之前,请确保你已经仔细阅读并理解了协议的相关条款。本项目严禁用于任何商业用途,并且只能用于学习和研究。如果在使用本项目的过程中产生任何问题或结果,我们不承担任何责任。同时,我们鼓励用户为这个项目的改进和发展提供反馈和建议。
🦈 安装
安装
pip 安装
pip install dimtown-spider -U
poetry 安装
poetry add dimtown-spider
🐟 使用
可见以下示例:
import asyncio
from dimtown import AnimeAvatar
if __name__ == "__main__":
aa = AnimeAvatar()
loop = asyncio.get_event_loop()
# 获取url列表
list_ = loop.run_until_complete(aa.get_animeavatar_list())
# 获取title列表
title_list = loop.run_until_complete(aa.get_animeavatar_title())
print(title_list)
# 获取url列表下所有图片
pic_list = loop.run_until_complete(aa.get_animeavatar_img(list_[0]))
print(pic_list)
🐖 注意事项
- 别爬太多
- 适度使用
- 健康生活
鸣谢
httpx ->一款同步异步兼容的网络请求库
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dimtown_spider-0.1.0.tar.gz
(7.8 kB
view hashes)
Built Distribution
Close
Hashes for dimtown_spider-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 06ba86bf1d3597238740f8e1dbfdfe78c3cc6de8f65e82ee1b618d2a26d247aa |
|
MD5 | 13fa3f07c9b225aaff6505f3e401331d |
|
BLAKE2b-256 | bea772082b24765046232157981649ce82ea49e4a8f7adb272fa959a833b3706 |