Ethscriptions commited on
Commit
f15e553
·
1 Parent(s): f4dbedd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -7
app.py CHANGED
@@ -9,18 +9,16 @@ st.title('磁力链接 BT 下载器')
9
  magnet_link = st.text_input('请输入磁力链接:')
10
 
11
  if magnet_link:
12
- # 创建一个会话并配置更多的设置以优化下载速度
13
  ses = lt.session()
14
-
15
- # 更具体的优化设置
16
  settings = {
17
- 'connections_limit': 500, # 最大连接数
18
- 'download_rate_limit': 0, # 下载速率限制 (0 表示无限制)
19
- 'upload_rate_limit': 0, # 上传速率限制 (0 表示无限制)
 
20
  }
21
  ses.apply_settings(settings)
22
 
23
- # 添加磁力链接以开始下载
24
  h = lt.add_magnet_uri(ses, magnet_link, {'save_path': './downloads'})
25
  st.write('开始下载...')
26
 
 
9
  magnet_link = st.text_input('请输入磁力链接:')
10
 
11
  if magnet_link:
12
+ # 创建一个会话并配置设置
13
  ses = lt.session()
 
 
14
  settings = {
15
+ 'connections_limit': 500, # 增加连接数限制
16
+ 'download_rate_limit': 0, # 不限制下载速度
17
+ 'upload_rate_limit': 0, # 不限制上传速度
18
+ # ... 其他设置
19
  }
20
  ses.apply_settings(settings)
21
 
 
22
  h = lt.add_magnet_uri(ses, magnet_link, {'save_path': './downloads'})
23
  st.write('开始下载...')
24