Sapphire - Imagine a framework
Sapphire - Imagine a framework

sapphire-support

Root Question Message

maksi
maksi1/27/2023
Error: Request aborted manually

Hi, sorry if the tag is wrong, I'm not really sure what all of them mean.
Anyways, I use the @sapphire/async-queue package and I came across an issue where calling the abortAll method led to a "Request aborted manually"-error.
Attached is the stack, in case that helps.
Favna
Favna1/27/2023
@242043489611808769 @139836912335716352
Vladdy
Vladdy1/27/2023
thats literally what abortAll does
Vladdy
Vladdy1/27/2023
aborts all requests manually
kyra
kyra1/27/2023
^
maksi
maksi1/27/2023
But is it supposed to throw an error?
kyra
kyra1/27/2023
Yes
maksi
maksi1/27/2023
How do I stop requests without an error?
kyra
kyra1/27/2023
Cancellable requests throw an error when they're cancelled
kyra
kyra1/27/2023
fetch does that, all of .NET does that, and so on
maksi
maksi1/27/2023
so what is the best practice when I want to cancel requests but don't want an error
Favna
Favna1/27/2023
try/catch im guessing... idk async-queue
maksi
maksi1/27/2023
alright, thanks for the help!
kyra
kyra1/27/2023
You already have a try/finally, so just add a catch clause
ContactFrequently Asked QuestionsJoin The DiscordBugs & Feature RequestsTerms & Privacy