import { waitUntilAsync } from "https://deno.land/x/retry@v2.0.0/wait/wait.ts";
wait for a function to complete within a givne duration or throw an exception.
Parameters
fn: () => Promise<RETURN_TYPE>
the async function to execute
Returns
Promise<RETURN_TYPE>