writing a tweet deleter, ran into issue where the lib I was using, their api wrappers would return the response on 200 or throwM it on 4xx
-
-
Replying to @alicemazzy
thus halting. which sucks because I don't want to have to do two api calls to check every id first, and I want to run it overnight
1 reply 0 retweets 1 like -
Replying to @alicemazzy
so I'm like, ok, read about Control.Monad.Catch, cool I'll just catchAll with (\_ -> pure ()) whatever who cares
2 replies 0 retweets 1 like -
Replying to @alicemazzy
except now it doesn't typecheck (and what exactly was happening confused me for awhile because the library's signatures are weird and...
1 reply 0 retweets 0 likes -
Replying to @alicemazzy
...because I'd been lazy with annotations so unification was failing in some random-ass place)
1 reply 0 retweets 1 like -
Replying to @alicemazzy
but it's simple! on success the thing is supposed to return a status object! so if you're wrapping with a catch that's what must come out
1 reply 0 retweets 0 likes
...sooo naturally I just fetch a status when the program starts and hold onto it to return from the handler every time it fails. as you do
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.