Mike Fährmann
a28fbbc3c6
[util] rename 'USERAGENT' to 'USERAGENT_GALLERYDL'
2026-01-03 10:31:48 +01:00
Mike Fährmann
e006d26c8e
Revert "use f-strings when building 'pattern'"
...
revert d7c97d5a97 .
2025-12-20 22:07:37 +01:00
Mike Fährmann
968597a302
yield 3-tuples for Message.Directory
...
adapt tuples to the same length and semantics as other messages
2025-12-05 21:39:52 +01:00
Mike Fährmann
d7c97d5a97
use f-strings when building 'pattern'
2025-10-20 21:23:11 +02:00
Mike Fährmann
6c71b279b6
[dt] update 'parse_datetime' calls with one argument
2025-10-17 22:49:41 +02:00
Mike Fährmann
085616e0a8
[dt] replace 'text.parse_datetime()' & 'text.parse_timestamp()'
2025-10-17 17:43:06 +02:00
Mike Fährmann
f2a72d8d1e
replace 'request(…).json()' with 'request_json(…)'
2025-06-29 17:50:19 +02:00
Mike Fährmann
9dbe33b6de
replace old %-formatted and .format(…) strings with f-strings ( #7671 )
...
mostly using flynt
https://github.com/ikamensh/flynt
2025-06-29 17:50:19 +02:00
Mike Fährmann
41191bb60a
'match.group(N)' -> 'match[N]' ( #7671 )
...
2.5x faster
2025-06-18 13:05:58 +02:00
Mike Fährmann
811b665e33
remove @staticmethod decorators
...
There might have been a time when calling a static method was faster
than a regular method, but that is no longer the case. According to
micro-benchmarks, it is 70% slower in CPython 3.13 and it also makes
executing the code of a class definition slower.
2025-06-12 22:50:52 +02:00
Mike Fährmann
b81fc5c124
replace text.rextract() with rextr()
2025-05-23 18:28:58 +02:00
Soblow "Opale" Xaselgio
07ac157acb
Accept Weasyl URLs of format /view/12345
...
Signed-off-by: Soblow "Opale" Xaselgio <113846014+Soblow@users.noreply.github.com >
2025-05-03 19:35:37 +02:00
Deer-Spangle
db89f4a545
[weasyl] Set gallery-dl user agent to match danbooru user agent, when making weasyl requests.
...
To fit with their bot ettiquette: https://projects.weasyl.com/bot-etiquette
2025-04-24 10:04:24 +01:00
Mike Fährmann
9d7f8f892d
[weasyl:favorite] update
...
- use 'self.groups' to access userid and username
- safe one request by not doing an explicit username -> userid lookup
- safe one request by following the 'Next' link instead of detecting an
empty page
2024-09-25 20:02:01 +02:00
Deer-Spangle
cbecaecc43
Fix infinite loop in Weasyl Favs downloader
2024-09-22 11:12:34 +01:00
Deer-Spangle
10543c64c6
Store favourites in the Favorites directory of the user's favs being downloaded, rather than in different directories for each submission
2024-08-31 15:54:04 +01:00
Deer-Spangle
01ace529b6
Fixing syntax on python 3.5, the sad days before f-strings
2024-08-31 15:22:39 +01:00
Deer-Spangle
311272f55a
Linting
2024-08-31 15:10:02 +01:00
Deer-Spangle
b1b01f56af
Add support for the readable URL format of Weasyl favourites page
2024-08-31 12:56:50 +01:00
Mike Fährmann
a453335a9f
remove test results in extractor modules
...
and add generic example URLs
2023-09-11 16:30:55 +02:00
Mike Fährmann
a383eca7f6
decouple extractor initialization
...
Introduce an 'initialize()' function that does the actual init
(session, cookies, config options) and can called separately from
the constructor __init__().
This allows, for example, to adjust config access inside a Job
before most of it already happened when calling 'extractor.find()'.
2023-07-25 22:16:16 +02:00
Mike Fährmann
b0cb4a1b9c
replace 'text.extract()' with 'text.extr()' where possible
2022-11-05 01:14:09 +01:00
Mike Fährmann
79dce8ae68
[weasyl] implement 'metadata' option ( #2610 )
2022-05-20 22:32:35 +02:00
Mike Fährmann
bd08ee2859
remove most 'yield Message.Version' statements
...
only leave them in oauth.py as noop results
2021-08-16 03:10:48 +02:00
Mike Fährmann
532ac79fb0
update extractor test results
2021-05-21 02:28:53 +02:00
tux93
10c279f285
Weasyl: Drop the &feature=submit part of the favourite extractor URL ( #1374 )
...
It's optional and requiring it forces users to escape those URLs because
of the ampersand
2021-03-12 16:56:04 +01:00
Mike Fährmann
8a98d3549a
[weasyl] create directory for each favorite submission
...
(#1032 )
2020-11-07 18:47:55 +01:00
Zanny
3ec60e894a
[weasyl] api-key authentication ( #1057 )
...
* [weasyl] support api keys
* [weasyl] document api-key authentication
* [weasyl] usernames can contain ~
2020-10-15 15:12:09 +02:00
Mike Fährmann
cc4ac80302
[weasyl] add 'favorite' extractor ( #1032 )
2020-09-26 13:09:03 +02:00
Mike Fährmann
e9cc719497
[weasyl] update and simplify
...
- simplify 'pattern' regexps
- parse 'posted_at' as 'date'
- use unaltered 'title' ({title!l:R /_/} to lowercase and replace spaces)
2020-09-26 02:10:45 +02:00
Zanny
ebb7737b9b
Weasyl Extractor ( #977 )
...
* weasyl extractor
* @kattjevfel suggested changes
* @mikf changes
2020-09-25 15:18:21 +02:00