uwt
Library
Module
Module type
Parameter
Class
Class type
update to libuv 1.23.0:
new functions:
Uwt.Misc.setpriority
,Uwt.Misc.getpriority
,
andUwt.Misc.getpid
. (Unix.getpid
doesn't returnGetCurrentProcessID
under Windows ...)
fix compilation
0.3.2 2018-07-16
update to libuv 1.22.0:
new function:
Uwt.Fs.lchmown
Change license to MIT
fix compilation under OCaml 4.07.0 (Windows)
add new
Uwt.error
codes:EHOSTDOWN
,EREMOTEIO
,ENOTTY
, andEFTYPE
0.3.0.2 2018-04-23
Maintenance release, because the bundled libuv version of the previous
release contains a serious regression.
update to libuv 1.20.2
File related functions inside
Uwt_compat.Lwt_io
now take
parameters of typeUnix.open_flag
instead ofUwt.Fs.uv_open_flag
0.3.0 2018-04-15
update to lwt 4.0.0:
The modules
Uwt_chan
andUwt_log
have been removed.Uwt_log
is available as an external libraryUwt_io.file_length
now fails withEISDIR
when used on a
directory (see https://github.com/ocsigen/lwt/issues/563)
update to libuv 1.20.0:
Uwt.Fs.copyfile
now supports file cloning
0.2.4 2018-02-10
fix compilation under OCaml 4.06.0 (Windows)
update to libuv 1.19.1:
new flags for
Uwt.Fs.openfile
:O_DIRECT
,O_EXLOCK
,O_NOATIME
,O_SYMLINK
,O_NOFOLLOW
, andO_DIRECTORY
new function:
Uwt.Pipe.chmod
to allow access from other usersnew function:
Uwt.Misc.getppid
(similar toUnix.getppid
, but also
supported under Windows).
0.2.3 2017-09-08
update to libuv 1.14.1
new functions from
Lwt_io
:Uwt_io.open_temp_file
andUwt_io.with_temp_file
Uwt_base.Sys_info.win_version
now reports your current Windows
version, even if your executable is not manifested.
0.2.2 2017-08-17
update to libuv 1.14.0:
new function:
Uwt.Fs.copyfile
Uwt.Poll.start
now supports watching for sysfs interrupts or TCP
out-of-band messagesUwt.Udp.try_send
now works under Windows
Uwt.Tcp.enable_keepalive
will now fail, if you pass anUwt.Tcp.t
handle to it, that doesn't wrap a socket yet. libuv silently ignores
the delay parameter in this case. You can useUwt.Tcp.init_ipv4
orUwt.Tcp.init_ipv6
instead ofUwt.Tcp.init
to circumvent this problem.Uwt_io
andUwt_log
have been updated to match the recentlwt.unix
changes.
0.2.1 2017-06-01
update internal libuv version to to 1.12.0
new functions:
Uwt.Signal.oneshot
andUwt_base.Misc.{put,set,unset}env
(added because of utf8 support
under windows)
0.2.0 2017-12-05
Uwt.Misc.guess_handle
now takes anUnix.file_descr
as parameter
(instead ofUwt.file
). This doesn't follow the libuv prototypes,
but makes more sense in the OCaml context.Uwt.Misc.guess_handle
can also classify UDP and TCP sockets on Windows.The IPC interface has changed:
Uwt.Stream.write2
has been removed. There are now properly typedUwt.Pipe.write2*
functions that can also send UDP handles to a
child process.Uwt.Stream.accept_raw
has been removed. InsteadUwt.Pipe.accept_ipc
must be used to accept handles that were
send via the libuv specific IPC interface.Uwt.Tcp.accept_raw
andUwt.Pipe.accept_raw
still exist.The
Uwt.Process.stdio
type has been
extended.Uwt.Process.spawn
now allows to create duplex stream
for IPC (previously not exposed by uwt)
Exception update: Many functions
Lwt.fail
withexception Unix_error of error * string * string
(or thefoo_exn
functions
will raise such exceptions). The first string component of this
exception is supposed to contain the function name. However there
was no consistency what was put there as name. If the function is
called uv_foo (oruv_xy_foo
,uv_foo_xy
, etc.) andman 2 foo
orman 3 foo
lists a closely related function that could be
wrapped byuv_foo
,foo
is used as function name (even if a
different, system dependent function is used internally by
libuv). This leads to more consistent behaviour regarding toUnix
andLwt_unix
. If it's not obvious (by just looking at the name),
which function is called by libuv,uv_foo
is used instead.new functions:
Uwt.Fs.pread
/Uwt.Fs.pwrite
/Uwt.Fs.pwritev
The mli files are now better documented.
Uwt.Tcp.keepalive
has been split in two functions:Uwt.Tcp.enable_keepalive
andUwt.Tcp.disable_keepalive
Tasks that are intended to run in libuv's threadpool and are
canceled viaLwt.cancel
now report the success of the cancellation
immediately instead of slightly deferred. So the following check
will work now:let s = Uwt.Fs.stat "foo" in (* more code *) assert (Lwt.state s = Lwt.Sleep); (* relevant use case *) Lwt.cancel s; match Lwt.state s with | Lwt.Sleep -> print_endline "cancel failed, the job is already running in background" | Lwt.Fail Lwt.Canceled -> print_endline "cancel success" | _ -> prerr_endline "Huh?"```
Bugs in the following functions have been fixed:
Uwt.Udp.set_multicast_ttl
(it rejected valid parameters)Uwt.Handle_ext.get_send_buffer_size
/Uwt.Handle_ext.get_recv_buffer_size
(they've returned wrong
results)Uwt.Stream.write2
(now ``Uwt.Pipe.write2`) (invalid memory
access under Windows, because libuv's interface slightly differs
on windows and unix)
0.1.0 2017-03-02
new functions: Uwt.Stream.writev and Uwt.Fs.writev
the opam package will now always use the internal copy of
libuv.prepare OCaml 4.05 support
internal libuv version updated to 1.11.0
avoid memcpy calls inside Uwt.Stream.read and Uwt.Udp.recv
(*nix only)Set up Travis for OS X testing
0.0.4 2016-11-04
API CHANGE:
Uwt_error
removed. Functions that possibly fail with
no-unix error codes will now always return('a, Uwt.error) result Lwt.t
, all other functions willLwt.fail
withUnix_error
.Unix.ECANCELED
is unfortunately missing, you have to
useUwt.of_unix_error x = Uwt.ECANCELED
instead.uwt now compiles with Microsoft Visual Studio (14.0 only)
internal libuv version updated to 1.10.0
update lwt.unix compatibility layer