Mastodon Feed: Post

Mastodon Feed

Boosted by glyph ("Glyph"):
aud@spectre.asta.lgbt (":: Asta :: [New Server]") wrote:

@glyph In between the docs and your help, I got it working! And I've avoided locking on crawling, I'm pretty sure (well... I haven't *tested*, explicitly, but you know)!

I think? I can probably simplify this but it's Good Enough For Now; I ran into problems with playwright having a wee hissy because something, somewhere, internally with playwright was going wonky. So doing this `await Deferred.fromFuture(asyncio.ensure_future(lousy_playwright_call()))` sorted it out. This is probably the only situation I'm going to be using this type of nasty library anyway; the comments on the code show my... distaste for having to use something like playwright at all...

https://codeberg.org/Astatide/balsalm/src/commit/5ae31ae5b55ba38c7dba68f61cd0ec92151a2b76/src/tir/crawler/crawler.py#L221

Also, while I did have to do some finagling, in the end the conversion to using the asyncio reactor was indeed quite trivial; just had to make sure I fired up a loop manually, as I didn't have one before

https://codeberg.org/Astatide/balsalm/src/commit/5ae31ae5b55ba38c7dba68f61cd0ec92151a2b76/src/tir/app.py#L6

ALSO super happy to hear that helping me is the "WEEE YAY INVINCIBILITY!!" fun version of help 😂