mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-22 02:32:33 +01:00
[8chan] also set TOS cookie for the previous day
This commit is contained in:
parent
2818973981
commit
51ceb33b6c
@ -29,8 +29,10 @@ class _8chanExtractor(Extractor):
|
||||
def _init(self):
|
||||
now = util.datetime_utcnow()
|
||||
domain = self.root.rpartition("/")[2]
|
||||
self.cookies.set("TOS20240928", "1", domain=domain)
|
||||
self.cookies.set(now.strftime("TOS%Y%m%d"), "1", domain=domain)
|
||||
self.cookies.set(
|
||||
now.strftime("TOS%Y%m%d"), "1", domain=domain)
|
||||
self.cookies.set(
|
||||
(now - timedelta(1)).strftime("TOS%Y%m%d"), "1", domain=domain)
|
||||
|
||||
@memcache()
|
||||
def cookies_prepare(self):
|
||||
|
@ -30,7 +30,7 @@ __tests__ = (
|
||||
"markdown" : str,
|
||||
"maxFileCount" : 5,
|
||||
"maxFileSize" : "32.00 MB",
|
||||
"maxMessageLength": 8001,
|
||||
"maxMessageLength": 12000,
|
||||
"message" : str,
|
||||
"mime" : str,
|
||||
"name" : "Anonymous",
|
||||
@ -73,7 +73,7 @@ __tests__ = (
|
||||
"#category": ("", "8chan", "board"),
|
||||
"#class" : _8chan._8chanBoardExtractor,
|
||||
"#pattern" : _8chan._8chanThreadExtractor.pattern,
|
||||
"#count" : range(24, 28),
|
||||
"#count" : range(24, 32),
|
||||
},
|
||||
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user