Skip to content

Fuyukai/turn-ring-turn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

import trio
from anyio import CancelScope
from century_ring import FileOpenFlag, FileOpenMode

from trt.sidecar import CURRENT_DIRECTORY, open_io_uring_loop


async def test():
    with CancelScope() as scope:
        async with open_io_uring_loop() as loop:
            fd = await loop.open_raw_file_handle(
                CURRENT_DIRECTORY,
                b"test.xt",
                FileOpenMode.WRITE_ONLY,
                {FileOpenFlag.CREATE_IF_NOT_EXISTS},
            )
            await loop.do_async_write(fd, b"test")
            scope.cancel()


trio.run(test)

About

System-∀99 ∀ Uring

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages