rabbit* Oh. Search.

This commit is contained in:
Lynne Megido 2020-08-24 18:18:01 +10:00
parent 48d87f336a
commit f75ff305c1
Signed by: lynnesbian
GPG key ID: F0A184B5213D9F90

View file

@ -94,7 +94,7 @@ class YahooAuctionsItem:
r = requests.get(f"https://page.auctions.yahoo.co.jp/jp/auction/{self.id}").text r = requests.get(f"https://page.auctions.yahoo.co.jp/jp/auction/{self.id}").text
# r = open("yahoo.html").read() # r = open("yahoo.html").read()
j = json.loads(re.match(r'.*var pageData ?= ?(\{.*?\});', r, re.DOTALL).group(1)) j = json.loads(re.match(r'.*var pageData ?= ?(\{.*?\});', r, re.DOTALL).group(1))
ae = re.match(r'自動延長.+\n.+>(.+)<.+', r) ae = re.search(r'自動延長.+\n.+>(.+)<.+', r)
if ae != None: if ae != None:
ae = ae.group(1) ae = ae.group(1)
self.auto_extension = (ae == "あり") self.auto_extension = (ae == "あり")