You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Node expects fd (file descriptor) as first argument, but rid is not that. Resource ids are internal Deno representation and they don't map to file descriptors.
That said, we are on track to deprecate these APIs (alongside Deno.seek() and Deno.seekSync() in 1.15 (denoland/deno#12107) and to be removed in 2.0; so that shouldn't be a big deal.
The text was updated successfully, but these errors were encountered:
We made a decision to keep file descriptors as rids in deno.ns rather than keep an internal mapping, if you're up for making a proper resource table implementation in userland we could do that instead.
After quick glance I found a few shims that are buggy - they do something else in Node than they intend to do in Deno.
Deno.read()
Deno.readSync()
Deno.write()
Deno.writeSync()
Namely:
Node expects
fd
(file descriptor) as first argument, butrid
is not that. Resource ids are internal Deno representation and they don't map to file descriptors.That said, we are on track to deprecate these APIs (alongside
Deno.seek()
andDeno.seekSync()
in 1.15 (denoland/deno#12107) and to be removed in 2.0; so that shouldn't be a big deal.The text was updated successfully, but these errors were encountered: