import structio
from structio.abc import AsyncResource
from structio.core.syscalls import check_cancelled