Skip to content

Commit 4966a86

Browse files
author
Taois
committed
feat: 发布新版本
1 parent 7a76f91 commit 4966a86

File tree

14 files changed

+540
-80
lines changed

14 files changed

+540
-80
lines changed

.env.development

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,5 @@ QQ_SMTP_AUTH_CODE =
3535
# 调试猫源-推荐开启
3636
CAT_DEBUG=1
3737
PYTHON_PATH=
38-
VIRTUAL_ENV=
38+
VIRTUAL_ENV=
39+
daemonMode=0

README.md

Lines changed: 5 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# drpyS(drpy-node)
22

33
nodejs作为服务端的drpy实现。全面升级异步写法
4-
~~积极开发中,每日一更~~,当前进度 `82%`
4+
~~积极开发中,每日一更~~,当前进度 `83%`
55
~~找工作中,随缘更新~~
66
上班当牛马,下班要带娃,阶段性佛系趁娃睡觉熬夜更新
77

@@ -25,6 +25,10 @@ nodejs作为服务端的drpy实现。全面升级异步写法
2525

2626
## 更新记录
2727

28+
### 20250823
29+
30+
更新至V1.2.18
31+
2832
### 20250822
2933

3034
更新至V1.2.17
@@ -37,22 +41,6 @@ nodejs作为服务端的drpy实现。全面升级异步写法
3741

3842
更新至V1.2.15
3943

40-
### 20250818
41-
42-
更新至V1.2.14
43-
44-
### 20250817
45-
46-
更新至V1.2.13
47-
48-
### 20250815
49-
50-
更新至V1.2.12
51-
52-
### 20250814
53-
54-
更新至V1.2.11
55-
5644
[点此查看完整更新记录](docs/updateRecord.md)
5745

5846
**注意事项**

docs/updateRecord.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# drpyS更新记录
22

3+
### 20250823
4+
5+
更新至V1.2.18
6+
7+
1. 优化python守护进程启动逻辑,无python环境的设备启动ds速度会有所提升
8+
2. 修了ds的 `荐片``ikanbot`
9+
3. 可以在配置里自行选择守护进程版本
10+
4. 新增 `七猫小说[书]` 的hipy源,移除同名的ds源
11+
12+
注意事项:本次更新有新增python依赖,大家请注意装一下py依赖
13+
314
### 20250822
415

516
更新至V1.2.17

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ const handleExit = async (signal) => {
100100
try {
101101
console.log(`\nReceived ${signal}, closing server...`);
102102
// Fastify 提供的关闭方法,内部会触发 onClose 钩子
103-
await fastify.close();
103+
await stop();
104104
console.log('Fastify closed successfully');
105105
process.exit(0);
106106
} catch (err) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "drpy-node",
3-
"version": "1.2.17",
3+
"version": "1.2.18",
44
"main": "index.js",
55
"type": "module",
66
"scripts": {

public/index.html

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</head>
99
<body>
1010
<h1 id="drpysdrpy-node">drpyS(drpy-node)</h1>
11-
<p>nodejs作为服务端的drpy实现。全面升级异步写法<br><del>积极开发中,每日一更</del>,当前进度 <code>82%</code><br><del>找工作中,随缘更新</del><br>上班当牛马,下班要带娃,阶段性佛系趁娃睡觉熬夜更新</p>
11+
<p>nodejs作为服务端的drpy实现。全面升级异步写法<br><del>积极开发中,每日一更</del>,当前进度 <code>83%</code><br><del>找工作中,随缘更新</del><br>上班当牛马,下班要带娃,阶段性佛系趁娃睡觉熬夜更新</p>
1212
<ul>
1313
<li><a href="docs/apidoc.md">接口文档</a> | <a href="docs/apiList.md">接口列表如定时任务</a> | <a href="https://github.com/waifu-project/movie/pull/135">小猫影视-待对接T4</a></li>
1414
<li><a href="/config?pwd=dzyyds">本地配置接口-动态本地</a></li>
@@ -29,20 +29,14 @@ <h1 id="drpysdrpy-node">drpyS(drpy-node)</h1>
2929
<li><a href="/cat/index.html">在线猫ds源主页</a></li>
3030
</ul>
3131
<h2 id="更新记录">更新记录</h2>
32+
<h3 id="20250823">20250823</h3>
33+
<p>更新至V1.2.18</p>
3234
<h3 id="20250822">20250822</h3>
3335
<p>更新至V1.2.17</p>
3436
<h3 id="20250821">20250821</h3>
3537
<p>更新至V1.2.16</p>
3638
<h3 id="20250819">20250819</h3>
3739
<p>更新至V1.2.15</p>
38-
<h3 id="20250818">20250818</h3>
39-
<p>更新至V1.2.14</p>
40-
<h3 id="20250817">20250817</h3>
41-
<p>更新至V1.2.13</p>
42-
<h3 id="20250815">20250815</h3>
43-
<p>更新至V1.2.12</p>
44-
<h3 id="20250814">20250814</h3>
45-
<p>更新至V1.2.11</p>
4640
<p><a href="docs/updateRecord.md">点此查看完整更新记录</a></p>
4741
<p><strong>注意事项</strong></p>
4842
<p>总是有人遇到各种奇葩问题,像什么没弹幕,访问/config/1服务马上崩溃等等,能自行解决最好,解决不了我建议你使用下方安装教程

spider/js/ikanbot.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ var rule = {
1717
类型: '影视',
1818
title: 'ikanbot',
1919
desc: 'ikanbot纯js版本',
20-
homeUrl: 'https://v.ikanbot.com',
20+
// homeUrl: 'https://v.ikanbot.com',
21+
homeUrl: 'https://v.aikanbot.com',
2122
url: '',
2223
searchUrl: '/search?q=**',
2324
searchable: 2,
@@ -67,7 +68,8 @@ var rule = {
6768
return {
6869
vod_id: item.attribs.href,
6970
vod_name: img.attribs.alt,
70-
vod_pic: getProxyUrl() + '&url=' + base64Encode(img.attribs['data-src']),
71+
// vod_pic: getProxyUrl() + '&url=' + base64Encode(img.attribs['data-src']),
72+
vod_pic: img.attribs['data-src'],
7173
vod_remarks: '',
7274
};
7375
}).toArray();
File renamed without changes.

spider/js/荐片.js

Lines changed: 100 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -9,31 +9,39 @@
99
title: '荐片',
1010
lang: 'ds'
1111
})
12-
*/var rule = {
12+
*/
13+
let imghost = '';
14+
15+
var rule = {
1316
title: '荐片',
1417
// host: 'http://api2.rinhome.com',
1518
//host: 'https://oiuzy.haitu33.com',
1619
host: 'https://dns.alidns.com/resolve?name=jpmobile.jianpiandns.com&type=TXT',
1720
hostJs: async function () {
18-
let {HOST} = this;
19-
log(HOST)
20-
var html = await request(HOST, {headers: {"User-Agent": MOBILE_UA}});
21-
let json = JSON.parse(html);
22-
let data = json.Answer[0].data.replace(/'|"/g, '').split(',');
23-
src = data[0];
24-
if (!src.startsWith('http')) {
25-
src = 'https://' + src;
26-
}
27-
HOST = src
21+
// let {HOST} = this;
22+
// log(HOST)
23+
// var html = await request(HOST, {headers: {"User-Agent": MOBILE_UA}});
24+
// let json = JSON.parse(html);
25+
// let data = json.Answer[0].data.replace(/'|"/g, '').split(',');
26+
// src = data[0];
27+
// if (!src.startsWith('http')) {
28+
// src = 'https://' + src;
29+
// }
30+
// HOST = src
31+
HOST = 'https://api.ubj83.com'
32+
imghost = `https://${JSON.parse((await req(`${HOST}/api/appAuthConfig`)).content).data.imgDomain}`;
2833
return HOST
2934
},
30-
homeUrl: '/api/tag/hand?code=unknown601193cf375db73d&channel=wandoujia',//网站的首页链接,用于分类获取和推荐获取
35+
// homeUrl: '/api/tag/hand?code=unknown601193cf375db73d&channel=wandoujia',//网站的首页链接,用于分类获取和推荐获取
36+
homeUrl: '/api/slide/list?pos_id=88',//网站的首页链接,用于分类获取和推荐获取
3137
// url:'/api/crumb/list?area=0&category_id=fyclass&page=fypage&type=0&limit=24&fyfilter',
3238
url: '/api/crumb/list?page=fypage&type=0&limit=24&fyfilter',
33-
class_name: '全部&电影&电视剧&动漫&综艺', // 筛选 /api/term/ad_fenlei?limit=10&page=1
34-
class_url: '0&1&2&3&4',
35-
detailUrl: '/api/node/detail?channel=wandoujia&token=&id=fyid',//二级详情拼接链接(json格式用)
36-
searchUrl: '/api/video/search?key=**&page=fypage',
39+
class_name: '电影&电视剧&动漫&综艺', // 筛选 /api/term/ad_fenlei?limit=10&page=1
40+
class_url: '1&2&3&4',
41+
// detailUrl: '/api/node/detail?channel=wandoujia&token=&id=fyid',//二级详情拼接链接(json格式用)
42+
detailUrl: '/api/video/detailv2?id=fyid',//二级详情拼接链接(json格式用)
43+
// searchUrl: '/api/video/search?key=**&page=fypage',
44+
searchUrl: '/api/v2/search/videoV2?key=**&category_id=88&page=fypage&pageSize=20',
3745
searchable: 2,
3846
quickSearch: 0,
3947
filterable: 1,
@@ -46,37 +54,78 @@
4654
3: {cateId: '3'},
4755
4: {cateId: '4'}
4856
},
57+
// headers: {
58+
// 'User-Agent': 'jianpian-android/350',
59+
// 'JPAUTH': 'y261ow7kF2dtzlxh1GS9EB8nbTxNmaK/QQIAjctlKiEv'
60+
// },
4961
headers: {
50-
'User-Agent': 'jianpian-android/350',
51-
'JPAUTH': 'y261ow7kF2dtzlxh1GS9EB8nbTxNmaK/QQIAjctlKiEv'
62+
'User-Agent': 'Mozilla/5.0 (Linux; Android 9; V2196A Build/PQ3A.190705.08211809; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/91.0.4472.114 Mobile Safari/537.36;webank/h5face;webank/1.0;netType:NETWORK_WIFI;appVersion:416;packageName:com.jp3.xg3',
5263
},
5364
timeout: 5000,
5465
limit: 8,
5566
play_parse: true,
56-
lazy: async function () {
57-
let {input} = this;
67+
lazy: async function (flag, id, flags) {
68+
// let {input} = this;
69+
// return {
70+
// parse: 0,
71+
// url: input,
72+
// jx: 0
73+
// }
74+
5875
return {
5976
parse: 0,
60-
url: input,
61-
jx: 0
77+
url: id.indexOf(".m3u8") > -1?id:`tvbox-xg:${id}`
6278
}
6379

6480
},
81+
parseList(html) {
82+
let res = JSON.parse(html);
83+
// console.log(res);
84+
85+
return res.data.map(item => ({
86+
vod_id: item.jump_id || item.id,
87+
vod_name: item.title,
88+
vod_pic: `${imghost}${item.thumbnail}`,
89+
vod_remarks: item.mask,
90+
style: {"type": "rect", "ratio": 1.33}
91+
}))
92+
},
93+
parseDetail(html) {
94+
let res = JSON.parse(html).data;
95+
let play_from = res.source_list_source.map(item => item.name).join('$$$').replace(/线/g, '边下边播');
96+
let play_url = res.source_list_source.map(play =>
97+
play.source_list.map(({source_name, url}) => `${source_name}$${url}`).join('#')
98+
).join('$$$');
99+
100+
var vod = {
101+
"type_name": '',
102+
"vod_year": res.year,
103+
"vod_area": res.area,
104+
"vod_remarks": res.mask,
105+
"vod_content": res.description,
106+
"vod_play_from": play_from,
107+
"vod_play_url": play_url
108+
};
109+
110+
return vod
111+
},
65112

66113
推荐: async function () {
67114
let {input} = this;
68115
var d = [];
69116
var html = await request(input);
70-
html = JSON.parse(html).data[0].video;
71-
html.forEach(it => {
72-
d.push({
73-
title: it.title,
74-
img: it.path + '@Referer=www.jianpianapp.com@User-Agent=jianpian-version353',
75-
desc: it.playlist.title + ' ⭐' + it.score,
76-
url: it.id
77-
})
78-
});
79-
return setResult(d);
117+
// console.log(html);
118+
// html = JSON.parse(html).data[0].video;
119+
// html.forEach(it => {
120+
// d.push({
121+
// title: it.title,
122+
// img: it.path + '@Referer=www.jianpianapp.com@User-Agent=jianpian-version353',
123+
// desc: it.playlist.title + ' ⭐' + it.score,
124+
// url: it.id
125+
// })
126+
// });
127+
// return setResult(d);
128+
return this.parseList(html);
80129
},
81130
// 一级:'json:data;title;path;playlist.title;id',
82131
一级: async function (tid) {
@@ -87,12 +136,16 @@
87136
input = HOST + '/api/video/search?key=' + tid + '&page=' + +MY_PAGE;
88137
}
89138
var d = [];
139+
// https://api.ubj83.com/api/crumb/list?page=1&type=0&limit=24&area=0&sort=update&year=0&category_id=0
140+
// console.log('全部:',input);
90141
let html = await request(input);
142+
// console.log(html);
91143
html = JSON.parse(html).data;
92144
html.forEach(it => {
93145
d.push({
94146
title: it.title,
95-
img: it.thumbnail || it.path,
147+
// img: it.thumbnail || it.path,
148+
img: `${imghost}${it.thumbnail || it.path}`,
96149
desc: (it.mask || it.playlist.title) + ' ⭐' + it.score,
97150
url: it.id
98151
})
@@ -113,7 +166,10 @@
113166
}
114167

115168
try {
169+
console.log(input);
116170
let html = await request(input);
171+
// console.log(html);
172+
return this.parseDetail(html);
117173
html = JSON.parse(html);
118174
let node = html.data;
119175
VOD = {
@@ -160,15 +216,16 @@
160216
let {input} = this;
161217
var d = [];
162218
let html = await request(input);
163-
html = JSON.parse(html).data;
164-
html.forEach(it => {
165-
d.push({
166-
title: it.title,
167-
img: it.thumbnail,
168-
desc: it.mask + ' ⭐' + it.score,
169-
url: it.id
170-
})
171-
});
172-
return setResult(d);
219+
return this.parseList(html);
220+
// html = JSON.parse(html).data;
221+
// html.forEach(it => {
222+
// d.push({
223+
// title: it.title,
224+
// img: it.thumbnail,
225+
// desc: it.mask + ' ⭐' + it.score,
226+
// url: it.id
227+
// })
228+
// });
229+
// return setResult(d);
173230
},
174231
}

spider/py/base/requirements.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@ pyquery
66
jsonpath
77
json5
88
jpype1
9-
pympler
9+
pympler
10+
jinja2

0 commit comments

Comments
 (0)