luv icon indicating copy to clipboard operation
luv copied to clipboard

uv.cancel

Open SinisterRectus opened this issue 6 years ago • 3 comments

Working on documenting uv_req_t in #409

According to libuv: uv_fs_t, uv_getaddrinfo_t, uv_getnameinfo_t and uv_work_t are cancellable.

However, uv_work_t is not cancellable in luv; uv.queue_work doesn't return any userdata. The request seems to be wrapped up in luv_work_t and/or luv_work_ctx_t.

Additionally, the req:cancel() method is not bound to any of the above request types.

SinisterRectus avatar Oct 15 '19 16:10 SinisterRectus

Luv not expose uv_req_t to lua, should we consider about cancel

zhaozg avatar Oct 16 '19 03:10 zhaozg

The uv_req_t type is not exposed, but sub-types are.

SinisterRectus avatar Oct 16 '19 16:10 SinisterRectus

req:cancel() added in #494. uv_work_t is still not cancellable, though.

squeek502 avatar May 12 '20 06:05 squeek502