mirror of
https://github.com/simon987/chan_feed.git
synced 2025-12-15 21:39:03 +00:00
Link to parent, version bump, add iichan
This commit is contained in:
@@ -57,19 +57,21 @@ class DesuChanHtmlChanHelper(ChanHelper):
|
||||
|
||||
op_el = soup.find("div", id=lambda tid: tid and tid[1:].isdigit())
|
||||
|
||||
tid = int(op_el.get("id")[1:])
|
||||
for post_el in op_el.find_all("table", recursive=False):
|
||||
*_, time = post_el.find("label").children
|
||||
yield {
|
||||
"id": int(post_el.find("td", attrs={"class", "reply"}).get("id")[5:]),
|
||||
"type": "post",
|
||||
"html": str(post_el),
|
||||
"time": int(datetime.datetime.strptime(time, "\n%y/%m/%d(%a)%H:%M").timestamp())
|
||||
"time": int(datetime.datetime.strptime(time, "\n%y/%m/%d(%a)%H:%M").timestamp()),
|
||||
"parent": tid
|
||||
}
|
||||
post_el.decompose()
|
||||
|
||||
*_, time = op_el.find("label").children
|
||||
yield {
|
||||
"id": int(op_el.get("id")[1:]),
|
||||
"id": tid,
|
||||
"type": "thread",
|
||||
"html": str(op_el),
|
||||
"time": int(datetime.datetime.strptime(time, "\n%y/%m/%d(%a)%H:%M").timestamp())
|
||||
|
||||
Reference in New Issue
Block a user