nonebot-plugin-parser 2.6.9__tar.gz → 2.6.10__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/PKG-INFO +1 -1
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/pyproject.toml +2 -2
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/pyproject.toml.orig +2 -2
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/__init__.py +1 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/douyin/__init__.py +14 -14
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/twitter.py +4 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/README.md +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/config.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/constants.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/download/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/download/rich.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/download/task.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/download/ytdlp.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/exception.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/helper.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/matchers/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/matchers/filter.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/matchers/rule.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/acfun/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/acfun/video.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/base.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/article.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/common.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/dynamic.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/favlist.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/live.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/opus.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/bilibili/video.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/cookie.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/data.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/douyin/aweme.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/kuaishou/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/kuaishou/states.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/nga.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/task.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/tiktok.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/utils.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/weibo/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/weibo/article.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/weibo/common.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/weibo/show.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/xiaohongshu/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/xiaohongshu/common.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/xiaohongshu/discovery.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/xiaohongshu/explore.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/youtube/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/parsers/youtube/meta.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/base.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/common/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/common/assets.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/common/font.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/common/renderer.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/default.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/htmlrender.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/HYSongYunLangHeiW.ttf +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/__init__.py +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/avatar.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/bilibili.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/douyin.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/1.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/2.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/3.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/4.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/5.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/6.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/7.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/8.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/fallback_pic/9.jpg +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/kuaishou.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/play.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/tiktok.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/twitter.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/weibo.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/xiaohongshu.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/resources/youtube.png +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/renders/templates/card.html.jinja2 +0 -0
- {nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/utils.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: nonebot-plugin-parser
|
|
3
|
-
Version: 2.6.
|
|
3
|
+
Version: 2.6.10
|
|
4
4
|
Summary: NoneBot2 链接分享解析 Alconna 版, 现支持B站|抖音|快手|微博|小红书|YouTube|TikTok|Twitter|AcFun|NGA
|
|
5
5
|
Keywords: acfun,bilibili,douyin,kuaishou,nga,nonebot,nonebot2,tiktok,twitter,video,weibo,xiaohongshu,youtube
|
|
6
6
|
Author: fllesser
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "nonebot-plugin-parser"
|
|
3
|
-
version = "2.6.
|
|
3
|
+
version = "2.6.10"
|
|
4
4
|
description = "NoneBot2 链接分享解析 Alconna 版, 现支持B站|抖音|快手|微博|小红书|YouTube|TikTok|Twitter|AcFun|NGA"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.10"
|
|
@@ -113,7 +113,7 @@ conflicts = [[
|
|
|
113
113
|
[tool.bumpversion]
|
|
114
114
|
tag = true
|
|
115
115
|
commit = true
|
|
116
|
-
current_version = "2.6.
|
|
116
|
+
current_version = "2.6.10"
|
|
117
117
|
message = "release: bump vesion from {current_version} to {new_version}"
|
|
118
118
|
|
|
119
119
|
[[tool.bumpversion.files]]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "nonebot-plugin-parser"
|
|
3
|
-
version = "2.6.
|
|
3
|
+
version = "2.6.10"
|
|
4
4
|
description = "NoneBot2 链接分享解析 Alconna 版, 现支持B站|抖音|快手|微博|小红书|YouTube|TikTok|Twitter|AcFun|NGA"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.10"
|
|
@@ -115,7 +115,7 @@ conflicts = [
|
|
|
115
115
|
[tool.bumpversion]
|
|
116
116
|
tag = true
|
|
117
117
|
commit = true
|
|
118
|
-
current_version = "2.6.
|
|
118
|
+
current_version = "2.6.10"
|
|
119
119
|
message = "release: bump vesion from {current_version} to {new_version}"
|
|
120
120
|
|
|
121
121
|
[[tool.bumpversion.files]]
|
|
@@ -41,6 +41,7 @@ class BilibiliParser(BaseParser):
|
|
|
41
41
|
platform: ClassVar[Platform] = Platform(name=PlatformEnum.BILIBILI, display_name="哔哩哔哩")
|
|
42
42
|
|
|
43
43
|
def __init__(self):
|
|
44
|
+
super().__init__()
|
|
44
45
|
self.headers = HEADERS.copy()
|
|
45
46
|
self._credential: Credential | None = None
|
|
46
47
|
self._cookies_file = pconfig.config_dir / "bilibili_cookies.json"
|
|
@@ -74,20 +74,6 @@ class DouyinParser(BaseParser):
|
|
|
74
74
|
timestamp=aweme.create_time,
|
|
75
75
|
url=aweme.share_url.split("?")[0],
|
|
76
76
|
)
|
|
77
|
-
if music := aweme.music:
|
|
78
|
-
if not music.is_original_sound:
|
|
79
|
-
if music.play_url.uri == "":
|
|
80
|
-
extra = json.loads(music.extra)
|
|
81
|
-
music_url = extra.get("original_song_url")
|
|
82
|
-
else:
|
|
83
|
-
music_url = music.play_url.uri
|
|
84
|
-
if music_url:
|
|
85
|
-
result.contents.append(
|
|
86
|
-
self.create_audio(
|
|
87
|
-
url_or_task=music_url,
|
|
88
|
-
duration=music.duration,
|
|
89
|
-
)
|
|
90
|
-
)
|
|
91
77
|
|
|
92
78
|
# 添加图片内容
|
|
93
79
|
if images := aweme.images:
|
|
@@ -107,6 +93,20 @@ class DouyinParser(BaseParser):
|
|
|
107
93
|
self.create_video(url_or_task=image_video.play_addr.url),
|
|
108
94
|
]
|
|
109
95
|
)
|
|
96
|
+
if music := aweme.music:
|
|
97
|
+
if not music.is_original_sound:
|
|
98
|
+
if music.play_url.uri == "":
|
|
99
|
+
extra = json.loads(music.extra)
|
|
100
|
+
music_url = extra.get("original_song_url")
|
|
101
|
+
else:
|
|
102
|
+
music_url = music.play_url.uri
|
|
103
|
+
if music_url:
|
|
104
|
+
result.contents.append(
|
|
105
|
+
self.create_audio(
|
|
106
|
+
url_or_task=music_url,
|
|
107
|
+
duration=music.duration,
|
|
108
|
+
)
|
|
109
|
+
)
|
|
110
110
|
# 添加视频内容
|
|
111
111
|
elif video := aweme.video:
|
|
112
112
|
result.video = self.create_video(
|
|
@@ -57,6 +57,10 @@ decoder = Decoder(VxTwitterResponse)
|
|
|
57
57
|
class TwitterParser(BaseParser):
|
|
58
58
|
platform: ClassVar[Platform] = Platform(name=PlatformEnum.TWITTER, display_name="小蓝鸟")
|
|
59
59
|
|
|
60
|
+
def __init__(self):
|
|
61
|
+
super().__init__()
|
|
62
|
+
self.headers = {"User-Agent": "python-httpx/0.28.1"}
|
|
63
|
+
|
|
60
64
|
@handle("x.com", r"x.com/[0-9-a-zA-Z_]{1,20}/status/([0-9]+)")
|
|
61
65
|
async def _parse(self, searched: re.Match[str]) -> ParseResult:
|
|
62
66
|
url = f"https://{searched.group(0)}"
|
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/__init__.py
RENAMED
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/config.py
RENAMED
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/constants.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/exception.py
RENAMED
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/helper.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{nonebot_plugin_parser-2.6.9 → nonebot_plugin_parser-2.6.10}/src/nonebot_plugin_parser/utils.py
RENAMED
|
File without changes
|