diff --git a/pt.json b/pt.json index 33c2aee..fb3109c 100644 --- a/pt.json +++ b/pt.json @@ -1110,7 +1110,7 @@ "pk": 19, "fields": { "created_at": "2022-07-20T11:03:57.583", - "updated_at": "2022-12-25T21:43:37.147", + "updated_at": "2022-12-27T00:09:47.202", "url": "https://www.pttime.org/", "name": "时间", "logo": "https://www.pttime.org/favicon.ico", @@ -1128,7 +1128,7 @@ "page_search": "torrents.php?search={}", "page_leeching": "getusertorrentlistajax.php?userid={}&type=leeching", "page_uploaded": "getusertorrentlistajax.php?userid={}&type=uploaded", - "page_seeding": "getusertorrentlistajax.php?userid={}&type=seeding", + "page_seeding": "getusertorrentlist.php?type=seeding&userid={}", "page_completed": "getusertorrentlistajax.php?userid={}&type=completed", "page_mybonus": "mybonus.php", "page_viewfilelist": "viewfilelist.php?id=", @@ -1178,7 +1178,7 @@ "leech_rule": "//i[@title=\"当前下载\"]/following-sibling::text()[1]", "seed_rule": "//i[@title=\"当前做种\"]/following-sibling::text()[1]", "record_count_rule": "/html/body/b/text()", - "seed_vol_rule": "//tr/td[3]", + "seed_vol_rule": "//b[contains(text(),\"资源总大小:\")]/following-sibling::text()[1]", "mailbox_rule": "//a[@href=\"messages.php\"]/font[contains(text(),\"条\")]/text()[1]", "notice_rule": "//a[@href=\"index.php\"]/font[contains(text(),\"条\")]/text()[1]", "hash_rule": "//tr[13]/td[2]/table/tbody/tr/td[1]/text()" diff --git a/pt_site/UtilityTool.py b/pt_site/UtilityTool.py index 1458734..1fca8ea 100644 --- a/pt_site/UtilityTool.py +++ b/pt_site/UtilityTool.py @@ -1853,8 +1853,11 @@ class PtSpider: 'https://pt.hdpost.top/', 'https://hd-torrents.org/', 'https://filelist.io/', + 'https://www.pttime.org/', ]: - seed_vol_size = ''.join(seeding_html.xpath(site.seed_vol_rule)).replace('i', '') + seed_vol_size = ''.join( + seeding_html.xpath(site.seed_vol_rule) + ).replace('i', '').replace(' ', ' ') seed_vol_all = FileSizeConvert.parse_2_byte(seed_vol_size) logger.info(f'做种信息: {seed_vol_all}') else: diff --git a/pt_site_site.json b/pt_site_site.json index 6f2cccb..c568bcc 100644 --- a/pt_site_site.json +++ b/pt_site_site.json @@ -1066,7 +1066,7 @@ { "id": 19, "created_at": "2022-07-20 11:03:57.583000", - "updated_at": "2022-12-25 21:43:37.147026", + "updated_at": "2022-12-27 00:09:47.202901", "name": "时间", "url": "https://www.pttime.org/", "logo": "https://www.pttime.org/favicon.ico", @@ -1082,7 +1082,7 @@ "page_search": "torrents.php?search={}", "page_leeching": "getusertorrentlistajax.php?userid={}&type=leeching", "page_uploaded": "getusertorrentlistajax.php?userid={}&type=uploaded", - "page_seeding": "getusertorrentlistajax.php?userid={}&type=seeding", + "page_seeding": "getusertorrentlist.php?type=seeding&userid={}", "page_completed": "getusertorrentlistajax.php?userid={}&type=completed", "page_mybonus": "mybonus.php", "page_viewfilelist": "viewfilelist.php?id=", @@ -1130,7 +1130,7 @@ "leech_rule": "//i[@title=\"当前下载\"]/following-sibling::text()[1]", "seed_rule": "//i[@title=\"当前做种\"]/following-sibling::text()[1]", "record_count_rule": "/html/body/b/text()", - "seed_vol_rule": "//tr/td[3]", + "seed_vol_rule": "//b[contains(text(),\"资源总大小:\")]/following-sibling::text()[1]", "mailbox_rule": "//a[@href=\"messages.php\"]/font[contains(text(),\"条\")]/text()[1]", "hash_rule": "//tr[13]/td[2]/table/tbody/tr/td[1]/text()", "notice_rule": "//a[@href=\"index.php\"]/font[contains(text(),\"条\")]/text()[1]",