Called with an error a metadata function threw, and the route it belongs to.
import type { ChainErrorHandler } from "@shadow-js/dusk/server";
type ChainErrorHandler = (error: unknown, routeId: string) => void